Conditions | 2 |
Paths | 1 |
Total Lines | 9 |
Code Lines | 4 |
Lines | 0 |
Ratio | 0 % |
Tests | 4 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
13 | 22 | private function createInjector(/*object */$target, string $property): \Closure |
|
14 | { |
||
15 | 22 | $injector = function (/*object */$object) use ($property): void { |
|
16 | if (null === $this->$property) { |
||
17 | $this->$property = $object; |
||
18 | } |
||
19 | 22 | }; |
|
20 | |||
21 | 22 | return $injector->bindTo($target, $this->findScope($target, $property)); |
|
22 | } |
||
53 |