| Conditions | 3 |
| Paths | 3 |
| Total Lines | 13 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 30 | private function extractNamespaceOfParentClass(string $class, string $parent): ?string |
||
| 31 | { |
||
| 32 | $lastPosition = mb_strripos($class, '\\'); |
||
| 33 | if ($lastPosition === 0) { |
||
| 34 | return null; |
||
| 35 | } |
||
| 36 | |||
| 37 | if ($lastPosition !== false) { |
||
| 38 | return $this->extractNamespace($class); |
||
| 39 | } |
||
| 40 | |||
| 41 | return $this->extractNamespace($parent); |
||
| 42 | } |
||
| 43 | |||
| 53 | } |