| Conditions | 3 |
| Paths | 3 |
| Total Lines | 9 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 22 | public function normalize($object, string $format = null, array $context = []): array |
||
| 23 | { |
||
| 24 | if (!$object instanceof FlattenException) { |
||
| 25 | throw new InvalidArgumentException(sprintf('The object must implement "%s".', FlattenException::class)); |
||
| 26 | } |
||
| 27 | $context += $this->defaultContext; |
||
| 28 | $debug = $this->debug && ($context['debug'] ?? true); |
||
| 29 | |||
| 30 | return $this->createResponse($debug, $object, $context); |
||
| 31 | } |
||
| 48 |