Log handled exceptions
This commit is contained in:
parent
07f19a80f4
commit
234ecc2c6d
2 changed files with 4 additions and 1 deletions
|
@ -89,7 +89,8 @@ abstract class BaseController
|
|||
$this->sessionSegment = $session->getSegment(self::class);
|
||||
$this->localeManager = $this->container->get('locale');
|
||||
$this->downloader = $this->config->getDownloader();
|
||||
$this->downloader->setLogger($this->container->get('logger'));
|
||||
$this->logger = $this->container->get('logger');
|
||||
$this->downloader->setLogger($this->logger);
|
||||
|
||||
if (!$this->config->stream) {
|
||||
// Force HTTP if stream is not enabled.
|
||||
|
|
|
@ -293,6 +293,8 @@ class FrontController extends BaseController
|
|||
*/
|
||||
public function error(Request $request, Response $response, Throwable $error)
|
||||
{
|
||||
$this->logger->error($error);
|
||||
|
||||
if ($this->config->debug) {
|
||||
$renderer = new HtmlErrorRenderer(true);
|
||||
$exception = $renderer->render($error);
|
||||
|
|
Loading…
Reference in a new issue