Conditions | 1 |
Paths | 1 |
Total Lines | 6 |
Code Lines | 4 |
Lines | 0 |
Ratio | 0 % |
Tests | 5 |
CRAP Score | 1 |
Changes | 0 |
1 | <?php |
||
36 | 2 | public function onKernelException(ExceptionEvent $event): void |
|
37 | { |
||
38 | 2 | $e = $event->getThrowable(); |
|
39 | 2 | $result = $this->converter->convert($e); |
|
40 | 2 | $response = new JsonResponse($result, $result['status']); |
|
41 | 2 | $event->setResponse($response->setEncodingOptions(JSON_UNESCAPED_UNICODE)); |
|
42 | 2 | } |
|
44 |