| Conditions | 3 |
| Paths | 2 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 3 |
| 1 | <?php |
||
| 37 | 24 | public function resolve($name) |
|
| 38 | { |
||
| 39 | if ( |
||
| 40 | 24 | $this->isRegistred($name) && |
|
| 41 | 21 | is_callable($this->registrations[$name]) |
|
| 42 | 18 | ) { |
|
| 43 | 20 | return $this->registrations[$name]; |
|
| 44 | } |
||
| 45 | |||
| 46 | 4 | throw new InvalidArgumentException(sprintf( |
|
| 47 | 4 | 'Could not resolve [%s] from the registrar.', $name |
|
| 48 | 3 | )); |
|
| 49 | } |
||
| 50 | } |
||
| 51 |