diff --git a/Src/Console/Application.php b/Src/Console/Application.php index b99e6223..54bab565 100644 --- a/Src/Console/Application.php +++ b/Src/Console/Application.php @@ -76,7 +76,7 @@ public function doRun(InputInterface $input, OutputInterface $output) { private function registerErrorHandler() { //设置了错误级别后只会收集错误级别内的日志, 容器确认后, 系统设置进行归类处理 $setting = iconfig()->getUserAppConfig('setting'); - $errorLevel = $setting['error_level'] ?? -1; + $errorLevel = $setting['error_level'] ?? ((ENV & RELEASE) === RELEASE ? E_ALL^E_NOTICE : -1); error_reporting($errorLevel); /** diff --git a/Src/Core/Config/Config.php b/Src/Core/Config/Config.php index 63c6afcb..e4105e25 100644 --- a/Src/Core/Config/Config.php +++ b/Src/Core/Config/Config.php @@ -78,7 +78,7 @@ public function __construct() { unset($env); //在加载配置前定义需要的常量 - !defined('RELEASE') && define('RELEASE', 0); + !defined('RELEASE') && define('RELEASE', 8); !defined('DEBUG') && define('DEBUG', 1); !defined('CLEAR_LOG') && define('CLEAR_LOG', 2); !defined('BACKTRACE') && define('BACKTRACE', 4);