has_roles should be is_granted in security upgrade file
This commit is contained in:
parent
395558cede
commit
2f1336e79f
@ -15,7 +15,7 @@ CHANGELOG
|
||||
|
||||
**After**
|
||||
```php
|
||||
if ($this->authorizationChecker->isGranted(new Expression("has_role('ROLE_USER') or has_role('ROLE_ADMIN')"))) {}
|
||||
if ($this->authorizationChecker->isGranted(new Expression("is_granted('ROLE_USER') or is_granted('ROLE_ADMIN')"))) {}
|
||||
// or:
|
||||
if ($this->authorizationChecker->isGranted('ROLE_USER')
|
||||
|| $this->authorizationChecker->isGranted('ROLE_ADMIN')
|
||||
|
Reference in New Issue
Block a user