pomaxa 10 лет назад
Родитель
Сommit
108bcff409
1 измененных файлов с 2 добавлено и 3 удалено
  1. 2 3
      src/Monolog/Formatter/ChromePHPFormatter.php

+ 2 - 3
src/Monolog/Formatter/ChromePHPFormatter.php

@@ -41,10 +41,9 @@ class ChromePHPFormatter implements FormatterInterface
     {
         // Retrieve the line and file if set and remove them from the formatted extra
         $backtrace = 'unknown';
-        if (isset($record['extra']['file']) && isset($record['extra']['line'])) {
+        if (isset($record['extra']['file'], $record['extra']['line'])) {
             $backtrace = $record['extra']['file'].' : '.$record['extra']['line'];
-            unset($record['extra']['file']);
-            unset($record['extra']['line']);
+            unset($record['extra']['file'], $record['extra']['line']);
         }
 
         $message = array('message' => $record['message']);