88use Symfony \Component \HttpKernel \Event \FilterControllerEvent ;
99use Symfony \Component \HttpKernel \Event \GetResponseEvent ;
1010use Symfony \Component \Security \Core \Authentication \Token \Storage \TokenStorageInterface ;
11- use Symfony \Component \Security \Core \Authorization \AuthorizationCheckerInterface ;
1211use Symfony \Component \Security \Core \User \UserInterface ;
1312
1413/**
@@ -23,23 +22,17 @@ final class RequestListener
2322 /** @var TokenStorageInterface|null */
2423 private $ tokenStorage ;
2524
26- /** @var AuthorizationCheckerInterface|null */
27- private $ authorizationChecker ;
28-
2925 /**
3026 * RequestListener constructor.
3127 * @param HubInterface $hub
3228 * @param TokenStorageInterface|null $tokenStorage
33- * @param AuthorizationCheckerInterface|null $authorizationChecker
3429 */
3530 public function __construct (
3631 HubInterface $ hub ,
37- ?TokenStorageInterface $ tokenStorage ,
38- ?AuthorizationCheckerInterface $ authorizationChecker
32+ ?TokenStorageInterface $ tokenStorage
3933 ) {
4034 $ this ->hub = $ hub ; // not used, needed to trigger instantiation
4135 $ this ->tokenStorage = $ tokenStorage ;
42- $ this ->authorizationChecker = $ authorizationChecker ;
4336 }
4437
4538 /**
@@ -68,7 +61,6 @@ public function onKernelRequest(GetResponseEvent $event): void
6861
6962 if (
7063 null !== $ token
71- && null !== $ this ->authorizationChecker
7264 && $ token ->isAuthenticated ()
7365 && $ token ->getUser ()
7466 ) {
0 commit comments