From 5c06c0870f8e425c2d4ed0f7c330c13e1605628e Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Tue, 20 Oct 2020 18:32:46 +0200 Subject: Dislay an error if an exception occurs in the error handler Related to #1598 --- application/front/controller/visitor/ErrorController.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'application/front/controller') diff --git a/application/front/controller/visitor/ErrorController.php b/application/front/controller/visitor/ErrorController.php index 10aa84c8..8da11172 100644 --- a/application/front/controller/visitor/ErrorController.php +++ b/application/front/controller/visitor/ErrorController.php @@ -28,10 +28,7 @@ class ErrorController extends ShaarliVisitorController // Internal error (any other Throwable) if ($this->container->conf->get('dev.debug', false)) { $this->assignView('message', $throwable->getMessage()); - $this->assignView( - 'stacktrace', - nl2br(get_class($throwable) .': '. PHP_EOL . $throwable->getTraceAsString()) - ); + $this->assignView('stacktrace', exception2text($throwable)); } else { $this->assignView('message', t('An unexpected error occurred.')); } -- cgit v1.2.3