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