File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -240,15 +240,17 @@ which contains request matchers and a corresponding set of attributes that
240
240
are required for the current user to get access to the application::
241
241
242
242
use Symfony\Component\HttpFoundation\RequestMatcher;
243
+ use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorage;
243
244
use Symfony\Component\Security\Http\AccessMap;
244
245
use Symfony\Component\Security\Http\Firewall\AccessListener;
245
246
246
247
$accessMap = new AccessMap();
248
+ $tokenStorage = new TokenStorage();
247
249
$requestMatcher = new RequestMatcher('^/admin');
248
250
$accessMap->add($requestMatcher, ['ROLE_ADMIN']);
249
251
250
252
$accessListener = new AccessListener(
251
- $securityContext ,
253
+ $tokenStorage ,
252
254
$accessDecisionManager,
253
255
$accessMap,
254
256
$authenticationManager
You can’t perform that action at this time.
0 commit comments