Conditions | 3 |
Paths | 3 |
Total Lines | 12 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Tests | 4 |
CRAP Score | 3.3332 |
Changes | 0 |
1 | <?php |
||
23 | 10 | public function updateEntity($entity, $data) |
|
24 | { |
||
25 | try { |
||
26 | 10 | foreach ((array)$data as $property => $value) { |
|
27 | 10 | $this->accessor->setValue($entity, $property, $value); |
|
28 | } |
||
29 | } catch (ExceptionInterface $exception) { |
||
30 | throw new EntityProcessingException($exception->getMessage(), $exception->getCode(), $exception); |
||
31 | } |
||
32 | |||
33 | 10 | return $entity; |
|
|
|||
34 | } |
||
35 | } |
||
36 |