Tweak a few error handling things.
This commit is contained in:
parent
35b3e8f398
commit
9db97c3285
|
@ -5,6 +5,15 @@
|
||||||
|
|
||||||
class Handler extends ExceptionHandler {
|
class Handler extends ExceptionHandler {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A list of the exception types that should not be reported.
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
protected $dontReport = [
|
||||||
|
'Symfony\Component\HttpKernel\Exception\HttpException'
|
||||||
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Report or log an exception.
|
* Report or log an exception.
|
||||||
*
|
*
|
||||||
|
@ -27,7 +36,14 @@ public function report(Exception $e)
|
||||||
*/
|
*/
|
||||||
public function render($request, Exception $e)
|
public function render($request, Exception $e)
|
||||||
{
|
{
|
||||||
return parent::render($request, $e);
|
if ($this->isHttpException($e))
|
||||||
|
{
|
||||||
|
return $this->renderHttpException($e);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return parent::render($request, $e);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue