Fix missing addExpressionLanguageProvider (used by service container to add expression providers)
This commit is contained in:
parent
d805dfd679
commit
6c70bc5211
@ -15,6 +15,7 @@ use Symfony\Component\Security\Core\Authentication\Token\TokenInterface;
|
|||||||
use Symfony\Component\Security\Core\Authentication\AuthenticationTrustResolverInterface;
|
use Symfony\Component\Security\Core\Authentication\AuthenticationTrustResolverInterface;
|
||||||
use Symfony\Component\Security\Core\Authorization\ExpressionLanguage;
|
use Symfony\Component\Security\Core\Authorization\ExpressionLanguage;
|
||||||
use Symfony\Component\Security\Core\Role\RoleHierarchyInterface;
|
use Symfony\Component\Security\Core\Role\RoleHierarchyInterface;
|
||||||
|
use Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface;
|
||||||
use Symfony\Component\ExpressionLanguage\Expression;
|
use Symfony\Component\ExpressionLanguage\Expression;
|
||||||
use Symfony\Component\HttpFoundation\Request;
|
use Symfony\Component\HttpFoundation\Request;
|
||||||
|
|
||||||
@ -43,6 +44,11 @@ class ExpressionVoter implements VoterInterface
|
|||||||
$this->roleHierarchy = $roleHierarchy;
|
$this->roleHierarchy = $roleHierarchy;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function addExpressionLanguageProvider(ExpressionFunctionProviderInterface $provider)
|
||||||
|
{
|
||||||
|
$this->expressionLanguage->registerProvider($provider);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*/
|
*/
|
||||||
|
Reference in New Issue
Block a user