Conditions | 2 |
Paths | 2 |
Total Lines | 11 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php declare(strict_types=1); |
||
52 | private static function convertViolationsToArray(ConstraintViolationListInterface $violations) : array |
||
53 | { |
||
54 | $result = []; |
||
55 | foreach ($violations as $violation) { |
||
56 | $result[] = [ |
||
57 | 'message' => $violation->getMessage(), |
||
58 | 'property' => $violation->getPropertyPath(), |
||
59 | ]; |
||
60 | } |
||
61 | |||
62 | return $result; |
||
63 | } |
||
65 |