mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-20 14:43:49 +00:00
Remove usage of deprecated Role class
This commit is contained in:
@@ -119,7 +119,7 @@ class EventVoter extends AbstractChillVoter implements ProvideRoleHierarchyInter
|
||||
|
||||
// subject is null. We check that at least one center is reachable
|
||||
$centers = $this->authorizationHelper
|
||||
->getReachableCenters($token->getUser(), new Role($attribute));
|
||||
->getReachableCenters($token->getUser(), $attribute);
|
||||
|
||||
return count($centers) > 0;
|
||||
|
||||
|
@@ -116,7 +116,7 @@ class ParticipationVoter extends AbstractChillVoter implements ProvideRoleHierar
|
||||
|
||||
// subject is null. We check that at least one center is reachable
|
||||
$centers = $this->authorizationHelper
|
||||
->getReachableCenters($token->getUser(), new Role($attribute));
|
||||
->getReachableCenters($token->getUser(), $attribute);
|
||||
|
||||
return count($centers) > 0;
|
||||
|
||||
|
Reference in New Issue
Block a user