| Conditions | 5 |
| Paths | 4 |
| Total Lines | 19 |
| Code Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 11 | public function process(ContainerBuilder $container) |
||
| 12 | { |
||
| 13 | if (!$container->has('kuleuven_authentication.service.shibboleth_attributes_injector_manager')) { |
||
| 14 | return; |
||
| 15 | } |
||
| 16 | |||
| 17 | $definition = $container->findDefinition('kuleuven_authentication.service.shibboleth_attributes_injector_manager'); |
||
| 18 | |||
| 19 | $taggedServices = $container->findTaggedServiceIds('kuleuven_authentication.shibboleth_attributes_injector'); |
||
| 20 | |||
| 21 | foreach ($taggedServices as $id => $tags) { |
||
| 22 | foreach ($tags as $attributes) { |
||
| 23 | $definition->addMethodCall('addProvider', [ |
||
| 24 | new Reference($id), |
||
| 25 | isset($attributes['priority']) ? $attributes['priority'] : 0, |
||
| 26 | ]); |
||
| 27 | } |
||
| 28 | } |
||
| 29 | } |
||
| 30 | } |
||
| 31 |