| Conditions | 2 |
| Paths | 2 |
| Total Lines | 11 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 7 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 24 | 50 | public function process(ContainerBuilder $container) |
|
| 25 | { |
||
| 26 | 50 | $reportersManagerDefinition = $container->getDefinition('tvi_monitor.reporters.manager'); |
|
| 27 | |||
| 28 | 50 | $reporterDefinitions = $container->findTaggedServiceIds(DiTags::CHECK_REPORTER); |
|
| 29 | |||
| 30 | 50 | foreach ($reporterDefinitions as $id => $reporterDefinition) { |
|
| 31 | 50 | $scope = $reporterDefinition[0]['scope'] ?? null; |
|
| 32 | 50 | $alias = $reporterDefinition[0]['alias']; |
|
| 33 | |||
| 34 | 50 | $reportersManagerDefinition->addMethodCall('addReporter', [$alias, new Reference($id), $scope]); |
|
| 35 | } |
||
| 38 |