From ac3137a16600a68fa7f6fde462be0cd197bd79ed Mon Sep 17 00:00:00 2001
From: Roeland Jago Douma <roeland@famdouma.nl>
Date: Thu, 2 Jul 2020 15:46:59 +0200
Subject: [PATCH] Check if debugMode is defined before using it

Else the sabre error page (where the var is not defined) will throw
warnings all the time.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
---
 core/templates/exception.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/core/templates/exception.php b/core/templates/exception.php
index a2b019b3289..f0bf171be64 100644
--- a/core/templates/exception.php
+++ b/core/templates/exception.php
@@ -14,7 +14,7 @@ style('core', ['styles', 'header']);
 	<ul>
 		<li><?php p($l->t('Remote Address: %s', [$_['remoteAddr']])) ?></li>
 		<li><?php p($l->t('Request ID: %s', [$_['requestID']])) ?></li>
-		<?php if ($_['debugMode']): ?>
+		<?php if (isset($_['debugMode']) && $_['debugMode'] === true): ?>
 			<li><?php p($l->t('Type: %s', [$_['errorClass']])) ?></li>
 			<li><?php p($l->t('Code: %s', [$_['errorCode']])) ?></li>
 			<li><?php p($l->t('Message: %s', [$_['errorMsg']])) ?></li>
-- 
GitLab