| Conditions | 2 |
| Paths | 2 |
| Total Lines | 15 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 10 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 17 | 5 | public function transform(ResponseInterface $response) |
|
| 18 | { |
||
| 19 | 5 | $data = $response->getData(); |
|
| 20 | |||
| 21 | 5 | foreach ($data['data'] as $k => $object) { |
|
| 22 | 5 | $data['data'][$k] = $this->serializer->deserialize( |
|
| 23 | 5 | json_encode($object), |
|
| 24 | 5 | $this->class, |
|
| 25 | 5 | 'json', |
|
| 26 | 5 | $this->context |
|
|
|
|||
| 27 | ); |
||
| 28 | } |
||
| 29 | |||
| 30 | 5 | $data = new ContentCollection($data); |
|
| 31 | 5 | $response->setData($data); |
|
| 32 | 5 | } |
|
| 51 | } |