Browse Source

Remove unneeded variable assignment.

ADmad 4 years ago
parent
commit
8f25dfe3cd
1 changed files with 2 additions and 3 deletions
  1. 2 3
      src/Core/functions.php

+ 2 - 3
src/Core/functions.php

@@ -252,10 +252,9 @@ if (!function_exists('triggerWarning')) {
      */
     function triggerWarning(string $message): void
     {
-        $stackFrame = 1;
         $trace = debug_backtrace();
-        if (isset($trace[$stackFrame])) {
-            $frame = $trace[$stackFrame];
+        if (isset($trace[1])) {
+            $frame = $trace[1];
             $frame += ['file' => '[internal]', 'line' => '??'];
             $message = sprintf(
                 '%s - %s, line: %s',