1
0
mirror of https://github.com/flarum/core.git synced 2025-07-19 07:41:22 +02:00

Stop logging errors that use a custom view

Having a custom view implies that a friendly message is displayed to
the user, in which case we can bet that the exception won't need to be
"debugged" per se.
This commit is contained in:
Toby Zerner
2018-11-11 17:57:55 +10:30
parent 2df5be7bcb
commit 4302687876

View File

@@ -81,11 +81,10 @@ class HandleErrorsWithView implements Middleware
$status = $errorCode;
}
// Log the exception (with trace)
$this->logger->debug($error);
if (! $this->view->exists($name = "flarum.forum::error.$status")) {
$name = 'flarum.forum::error.default';
$this->logger->error($error);
}
$view = $this->view->make($name)