Serializer/Normalizer/FlattenExceptionHandler.php 1 location
|
@@ 105-109 (lines=5) @@
|
102 |
|
|
103 |
|
$showMessage = $this->messagesMap->resolveFromClassName($exception->getClass()); |
104 |
|
|
105 |
|
if ($showMessage || $this->debug) { |
106 |
|
$message = $exception->getMessage(); |
107 |
|
} else { |
108 |
|
$message = Response::$statusTexts[$statusCode] ?? 'error'; |
109 |
|
} |
110 |
|
|
111 |
|
if ($this->rfc7807) { |
112 |
|
return [ |
Serializer/Normalizer/FlattenExceptionNormalizer.php 1 location
|
@@ 49-53 (lines=5) @@
|
46 |
|
|
47 |
|
$showMessage = $this->messagesMap->resolveFromClassName($exception->getClass()); |
48 |
|
|
49 |
|
if ($showMessage || $this->debug) { |
50 |
|
$message = $exception->getMessage(); |
51 |
|
} else { |
52 |
|
$message = Response::$statusTexts[$statusCode] ?? 'error'; |
53 |
|
} |
54 |
|
|
55 |
|
if ($this->rfc7807) { |
56 |
|
if ('json' === $format) { |