diff --git a/lib/private/Session/Internal.php b/lib/private/Session/Internal.php index f02f1c2541ccd..285b6fd796037 100644 --- a/lib/private/Session/Internal.php +++ b/lib/private/Session/Internal.php @@ -181,7 +181,9 @@ public function reopen() { * @throws \ErrorException */ public function trapError(int $errorNumber, string $errorString) { - throw new \ErrorException($errorString); + if ($errorNumber & E_ERROR) { + throw new \ErrorException($errorString); + } } /**