From 25d5f7447bbbcc133fdf1e9994a0e3e1e045b9db Mon Sep 17 00:00:00 2001 From: David Grudl Date: Tue, 27 Dec 2016 19:13:06 +0100 Subject: [PATCH] Debugger::shutdownHandler() always unsets $reserved --- src/Tracy/Debugger.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Tracy/Debugger.php b/src/Tracy/Debugger.php index ee2d9b492..a4c55b2a6 100644 --- a/src/Tracy/Debugger.php +++ b/src/Tracy/Debugger.php @@ -240,6 +240,7 @@ public static function shutdownHandler() if (!self::$reserved) { return; } + self::$reserved = NULL; $error = error_get_last(); if (in_array($error['type'], [E_ERROR, E_CORE_ERROR, E_COMPILE_ERROR, E_PARSE, E_RECOVERABLE_ERROR, E_USER_ERROR], TRUE)) { @@ -249,7 +250,6 @@ public static function shutdownHandler() ); } elseif (self::$showBar && !self::$productionMode) { - self::$reserved = NULL; self::removeOutputBuffers(FALSE); self::getBar()->render(); } @@ -264,7 +264,7 @@ public static function shutdownHandler() */ public static function exceptionHandler($exception, $exit = TRUE) { - if (!self::$reserved) { + if (!self::$reserved && $exit) { return; } self::$reserved = NULL;