Conditions | 3 |
Paths | 2 |
Total Lines | 12 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
29 | public function validatePlugin($plugin) |
||
30 | { |
||
31 | if ($plugin instanceof ClonerInterface) { |
||
32 | return; |
||
33 | } |
||
34 | |||
35 | throw new Exception\RuntimeException(sprintf( |
||
36 | 'Plugin of type %s is invalid; must implement %s', |
||
37 | (is_object($plugin) ? get_class($plugin) : gettype($plugin)), |
||
38 | ClonerInterface::class |
||
39 | )); |
||
40 | } |
||
41 | } |
||
42 |