Skip to content

Commit

Permalink
Add null check for previous error handler
Browse files Browse the repository at this point in the history
  • Loading branch information
pavelzotikov committed Oct 8, 2024
1 parent 654dc0a commit 5f8f0a0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Handler.php
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,9 @@ public function handleError(int $level, string $message, string $file, int $line
if ($event !== null) {
$this->send($event);

return false !== ($this->previousErrorHandler)($level, $message, $file, $line);
if (null !== $this->previousErrorHandler) {
return false !== ($this->previousErrorHandler)($level, $message, $file, $line);
}
}

return false;
Expand Down

0 comments on commit 5f8f0a0

Please sign in to comment.