diff options
Diffstat (limited to 'system/core/Loader.php')
-rw-r--r-- | system/core/Loader.php | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/system/core/Loader.php b/system/core/Loader.php index 72497c724..5c7a7eff8 100644 --- a/system/core/Loader.php +++ b/system/core/Loader.php @@ -79,7 +79,7 @@ class CI_Loader { { if (is_array($library)) { - foreach($library as $class) + foreach ($library as $read) { $this->library($class, $params); } @@ -117,7 +117,7 @@ class CI_Loader { { if (is_array($model)) { - foreach($model as $babe) + foreach ($model as $babe) { $this->model($babe); } @@ -965,7 +965,15 @@ class CI_Loader { */ function _ci_autoloader() { - include_once(APPPATH.'config/autoload'.EXT); + if (file_exists(APPPATH.'config/'.ENVIRONMENT.'/autoload'.EXT)) + { + include_once(APPPATH.'config/'.ENVIRONMENT.'/autoload'.EXT); + } + else + { + include_once(APPPATH.'config/autoload'.EXT); + } + if ( ! isset($autoload)) { @@ -1093,4 +1101,4 @@ class CI_Loader { } /* End of file Loader.php */ -/* Location: ./system/core/Loader.php */
\ No newline at end of file +/* Location: ./system/core/Loader.php */ |