| Conditions | 2 | 
| Paths | 2 | 
| Total Lines | 12 | 
| Code Lines | 7 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 0 | ||
| 1 | <?php | ||
| 85 | public function getReceiver(string $name) | ||
| 86 |     { | ||
| 87 |         $classPath = explode('\\', get_called_class()); | ||
| 88 | $class = (string)$this->getApi() | ||
| 89 |                                   ->sprintf(':namespace\:class\:method', __NAMESPACE__, end($classPath), $name); | ||
| 90 | |||
| 91 |         if (class_exists($class)) { | ||
| 92 | return new $class($this); | ||
| 93 | } | ||
| 94 | |||
| 95 | return null; | ||
| 96 | } | ||
| 97 | } |