logger.php: Don't output Panic messages unless debugging is on. Fixes #2460

pull/2518/head
Matthew Noorenberghe 2019-02-09 18:51:30 -08:00
parent 255806bd54
commit c9d597dced
1 changed files with 4 additions and 1 deletions

View File

@ -477,7 +477,10 @@ function Panic( $string ) {
}
}
Logger::fetch()->logPrint( Logger::PANIC, $string.$backtrace );
die( $string );
if (Logger::fetch()->debugOn()) {
echo $string;
}
exit(1);
}
function ErrorHandler( $error, $string, $file, $line ) {