增加record_trace配置参数用于日志记录trace信息

This commit is contained in:
thinkphp
2017-07-04 19:02:33 +08:00
parent 90d71bbc76
commit 0cfb72c6b5
2 changed files with 6 additions and 0 deletions

View File

@@ -52,6 +52,10 @@ class Handle
$log = "[{$data['code']}]{$data['message']}";
}
if (Config::get('record_trace')) {
$log .= "\r\n" . $exception->getTraceAsString();
}
Log::record($log, 'error');
}
}