8000 [ErrorHandler] made IDEs and static analysis tools happy · symfony/symfony@7dd9dbf · GitHub
[go: up one dir, main page]

Skip to content

Commit 7dd9dbf

Browse files
committed
[ErrorHandler] made IDEs and static analysis tools happy
1 parent 45526a1 commit 7dd9dbf

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/Symfony/Component/ErrorCatcher/ErrorRenderer/ErrorRenderer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ public function render($exception, string $format = 'html'): string
6262
throw new ErrorRendererNotFoundException(sprintf('No error renderer found for format "%s".', $format));
6363
}
6464

65-
if (!$exception instanceof FlattenException) {
65+
if ($exception instanceof \Exception) {
6666
$exception = FlattenException::create($exception);
6767
}
6868

src/Symfony/Component/ErrorCatcher/ExceptionHandler.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ public function handle(\Exception $exception)
160160
*/
161161
public function sendPhpResponse($exception)
162162
{
163-
if (!$exception instanceof FlattenException) {
163+
if ($exception instanceof \Exception) {
164164
$exception = FlattenException::create($exception);
165165
}
166166

0 commit comments

Comments
 (0)
0