Skip to content
This repository was archived by the owner on Dec 9, 2023. It is now read-only.

Commit 45b2136

Browse files
committed
Avoid warning with Xdebug 3 with develop mode disabled
1 parent 157bbec commit 45b2136

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

Exception/FatalErrorException.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,7 @@ public function __construct(string $message, int $code, int $severity, string $f
3535

3636
$this->setTrace($trace);
3737
} elseif (null !== $traceOffset) {
38-
if (\function_exists('xdebug_get_function_stack')) {
39-
$trace = xdebug_get_function_stack();
38+
if (\function_exists('xdebug_get_function_stack') && $trace = @xdebug_get_function_stack()) {
4039
if (0 < $traceOffset) {
4140
array_splice($trace, -$traceOffset);
4241
}

0 commit comments

Comments
 (0)