| Conditions | 5 |
| Paths | 4 |
| Total Lines | 17 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 4 |
| CRAP Score | 5.2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 33 | 12 | protected function initializeListeners(string $eventName, string $loweredClass, string $format): array |
|
| 34 | { |
||
| 35 | $listeners = parent::initializeListeners($eventName, $loweredClass, $format); |
||
| 36 | 4 | ||
| 37 | foreach ($listeners as &$listener) { |
||
| 38 | if (!\is_array($listener[0]) || !\is_string($listener[0][0])) { |
||
| 39 | continue; |
||
| 40 | 4 | } |
|
| 41 | |||
| 42 | if (!$this->container->has($listener[0][0])) { |
||
| 43 | 16 | continue; |
|
| 44 | } |
||
| 45 | |||
| 46 | $listener[0][0] = $this->container->get($listener[0][0]); |
||
| 47 | } |
||
| 48 | |||
| 49 | return $listeners; |
||
| 50 | } |
||
| 52 |