8000 [ErrorCatcher] Make IDEs and static analysis tools happy by fabpot · Pull Request #32221 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[ErrorCatcher] Make IDEs and static analysis tools happy #32221

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 27, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
[ErrorHandler] made IDEs and static analysis tools happy
  • Loading branch information
fabpot committed Jun 27, 2019
commit 7dd9dbf28d07afc1d261a50cf581d4d9a579d66b
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public function render($exception, string $format = 'html'): string
throw new ErrorRendererNotFoundException(sprintf('No error renderer found for format "%s".', $format));
}

if (!$exception instanceof FlattenException) {
if ($exception instanceof \Exception) {
$exception = FlattenException::create($exception);
}

Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Component/ErrorCatcher/ExceptionHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ public function handle(\Exception $exception)
*/
public function sendPhpResponse($exception)
{
if (!$exception instanceof FlattenException) {
if ($exception instanceof \Exception) {
$exception = FlattenException::create($exception);
}

Expand Down
0