| Conditions | 2 |
| Paths | 2 |
| Total Lines | 11 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 3 |
| CRAP Score | 2.7462 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 31 | 18 | public function hydrate($object, array $data) : void |
|
| 32 | { |
||
| 33 | 18 | if (! $object instanceof HydratableInterface) { |
|
| 34 | throw new InvalidArgumentException(sprintf( |
||
| 35 | 'Class %s does not implement %s.', |
||
| 36 | get_class($object), |
||
| 37 | HydratableInterface::class |
||
| 38 | )); |
||
| 39 | } |
||
| 40 | |||
| 41 | 18 | $object->hydrate($data, $this->objectManager); |
|
| 42 | 18 | } |
|
| 44 |