From d1ba4930301a5f957d952ea80aeeb806f30731f3 Mon Sep 17 00:00:00 2001 From: "Alexander A. Klimov" Date: Fri, 4 Dec 2020 12:15:13 +0100 Subject: [PATCH] ApplicationBootstrap#setupErrorHandling(): migrate error handler to PHP 8 ... as recommended here: https://www.php.net/manual/de/migration80.incompatible.php refs #4287 --- library/Icinga/Application/ApplicationBootstrap.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/Icinga/Application/ApplicationBootstrap.php b/library/Icinga/Application/ApplicationBootstrap.php index 04cc930d20..39be9bf5c4 100644 --- a/library/Icinga/Application/ApplicationBootstrap.php +++ b/library/Icinga/Application/ApplicationBootstrap.php @@ -605,7 +605,7 @@ protected function setupErrorHandling() ini_set('display_startup_errors', 1); ini_set('display_errors', 1); set_error_handler(function ($errno, $errstr, $errfile, $errline) { - if (error_reporting() === 0) { + if (!(error_reporting() & $errno)) { // Error was suppressed with the @-operator return false; // Continue with the normal error handler }