File tree Expand file tree Collapse file tree 2 files changed +3
-6
lines changed
DependencyInjection/Compiler Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -27,11 +27,8 @@ public function process(ContainerBuilder $container)
27
27
{
28
28
$ definition = $ container ->getDefinition ('fos_oauth_server.security.authentication.listener ' );
29
29
30
- if ($ container ->hasDefinition ('security.token_storage ' )) {
31
- $ tokenStorageReference = new Reference ('security.token_storage ' );
32
- } else {
33
- $ tokenStorageReference = new Reference ('security.context ' );
30
+ if ($ container ->hasDefinition ('security.token_storage ' ) === false ) {
31
+ $ definition ->replaceArgument (0 , new Reference ('security.context ' ));
34
32
}
35
- $ definition ->replaceArgument (0 , $ tokenStorageReference );
36
33
}
37
34
}
Original file line number Diff line number Diff line change 18
18
</service >
19
19
20
20
<service id =" fos_oauth_server.security.authentication.listener" class =" %fos_oauth_server.security.authentication.listener.class%" public =" false" >
21
- <argument /> <!-- security.token_storage or security.context for Symfony < 2.6 -- >
21
+ <argument type = " service " id = " security.token_storage" / >
22
22
<argument type =" service" id =" security.authentication.manager" />
23
23
<argument type =" service" id =" fos_oauth_server.server" />
24
24
</service >
You can’t perform that action at this time.
0 commit comments