diff --git a/library/think/App.php b/library/think/App.php index f6ed5fdf..6f2d7558 100644 --- a/library/think/App.php +++ b/library/think/App.php @@ -492,7 +492,7 @@ class App $dir = CONF_PATH . $module . 'extra'; $files = scandir($dir); foreach ($files as $file) { - if (strpos($file, CONF_EXT)) { + if (pathinfo($file, PATHINFO_EXTENSION) === CONF_EXT) { $filename = $dir . DS . $file; Config::load($filename, pathinfo($file, PATHINFO_FILENAME)); }