From bd6a814e66643a622ff535664c608b2939af299d Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Thu, 22 Jan 2015 16:41:25 +0200 Subject: Don't try to include config/autoload.php if it doesn't exist Related: #3497 --- system/core/Loader.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/system/core/Loader.php b/system/core/Loader.php index 6371ca3c7..20b26d80f 100644 --- a/system/core/Loader.php +++ b/system/core/Loader.php @@ -1232,7 +1232,11 @@ class CI_Loader { */ protected function _ci_autoloader() { - include(APPPATH.'config/autoload.php'); + if (file_exists(APPPATH.'config/config.php')) + { + include(APPPATH.'config/autoload.php'); + } + if (file_exists(APPPATH.'config/'.ENVIRONMENT.'/autoload.php')) { include(APPPATH.'config/'.ENVIRONMENT.'/autoload.php'); -- cgit v1.2.3-24-g4f1b