[ErrorHandler] made IDEs and static analysis tools happy

This commit is contained in:
Fabien Potencier 2019-06-27 15:32:52 +02:00
parent 45526a18c6
commit 7dd9dbf28d
2 changed files with 2 additions and 2 deletions

View File

@ -62,7 +62,7 @@ class ErrorRenderer
throw new ErrorRendererNotFoundException(sprintf('No error renderer found for format "%s".', $format));
}
if (!$exception instanceof FlattenException) {
if ($exception instanceof \Exception) {
$exception = FlattenException::create($exception);
}

View File

@ -160,7 +160,7 @@ class ExceptionHandler
*/
public function sendPhpResponse($exception)
{
if (!$exception instanceof FlattenException) {
if ($exception instanceof \Exception) {
$exception = FlattenException::create($exception);
}