@@ -78,7 +78,7 @@ discard block |
||
78 | 78 | break; |
79 | 79 | |
80 | 80 | default: |
81 | - if(isset($context['exception']) && $context['exception'] instanceof \Throwable){ |
|
81 | + if (isset($context['exception']) && $context['exception'] instanceof \Throwable) { |
|
82 | 82 | Debugger::visualDump($context['exception'], 'Uncaught '.get_class($context['exception']), true); |
83 | 83 | } |
84 | 84 | else |
@@ -116,11 +116,11 @@ discard block |
||
116 | 116 | array_fill_keys([E_ERROR, E_PARSE, E_CORE_ERROR, E_COMPILE_ERROR, E_USER_ERROR, E_RECOVERABLE_ERROR], LogLevel::ALERT) |
117 | 117 | + array_fill_keys([E_WARNING, E_CORE_WARNING, E_COMPILE_WARNING, E_USER_WARNING], LogLevel::CRITICAL) |
118 | 118 | + array_fill_keys([E_NOTICE, E_USER_NOTICE], LogLevel::ERROR) |
119 | - + array_fill_keys([E_STRICT,E_DEPRECATED,E_USER_DEPRECATED,E_ALL], LogLevel::DEBUG); |
|
119 | + + array_fill_keys([E_STRICT, E_DEPRECATED, E_USER_DEPRECATED, E_ALL], LogLevel::DEBUG); |
|
120 | 120 | } |
121 | 121 | |
122 | 122 | if (!isset(self::$level_mapping[$level])) { |
123 | - throw new \Exception(__FUNCTION__ . "($level): $level is unknown"); |
|
123 | + throw new \Exception(__FUNCTION__."($level): $level is unknown"); |
|
124 | 124 | } |
125 | 125 | |
126 | 126 | return self::$level_mapping[$level]; |
@@ -80,9 +80,9 @@ |
||
80 | 80 | default: |
81 | 81 | if(isset($context['exception']) && $context['exception'] instanceof \Throwable){ |
82 | 82 | Debugger::visualDump($context['exception'], 'Uncaught '.get_class($context['exception']), true); |
83 | + } else { |
|
84 | + Debugger::visualDump($message, $level, true); |
|
83 | 85 | } |
84 | - else |
|
85 | - Debugger::visualDump($message, $level, true); |
|
86 | 86 | http_response_code(500); |
87 | 87 | break; |
88 | 88 | } |