From 253ccaaad0171ae49054fbc13a5fe0bebd5e419e Mon Sep 17 00:00:00 2001 From: thinkphp Date: Fri, 22 Jul 2016 18:31:45 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96config=E6=8C=87=E4=BB=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/console/command/optimize/Config.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library/think/console/command/optimize/Config.php b/library/think/console/command/optimize/Config.php index 3541e3be..b76ea55f 100644 --- a/library/think/console/command/optimize/Config.php +++ b/library/think/console/command/optimize/Config.php @@ -54,12 +54,12 @@ class Config extends Command $config = \think\Config::load(CONF_PATH . $module . 'config' . CONF_EXT); // 加载应用状态配置 - if ($config['app_status']) { + if ($module && $config['app_status']) { $config = \think\Config::load(CONF_PATH . $module . $config['app_status'] . CONF_EXT); } // 读取扩展配置文件 - if ($config['extra_config_list']) { + if ($module && $config['extra_config_list']) { foreach ($config['extra_config_list'] as $name => $file) { $filename = CONF_PATH . $module . $file . CONF_EXT; \think\Config::load($filename, is_string($name) ? $name : pathinfo($filename, PATHINFO_FILENAME));