summaryrefslogtreecommitdiffstats
path: root/system/core
diff options
context:
space:
mode:
authordchill42 <dchill42@gmail.com>2012-10-15 00:16:16 +0200
committerdchill42 <dchill42@gmail.com>2012-10-15 00:16:16 +0200
commit92e5511d9b7667314c2a292c889f283c2f70e22a (patch)
tree71548133d4f702938b9f11831b13a6019b661a80 /system/core
parente9435dc7e5a4a9779eb83d8adf172fabf47ab5a6 (diff)
Reverted autoloader change now that APPPATH is in VFS
Signed-off-by: dchill42 <dchill42@gmail.com>
Diffstat (limited to 'system/core')
-rw-r--r--system/core/Loader.php12
1 files changed, 5 insertions, 7 deletions
diff --git a/system/core/Loader.php b/system/core/Loader.php
index ed830e2dd..75e93608a 100644
--- a/system/core/Loader.php
+++ b/system/core/Loader.php
@@ -1140,16 +1140,13 @@ class CI_Loader {
*/
protected function _ci_autoloader()
{
- // Get autoloader file from config path
- $CI =& get_instance();
- $path = reset($CI->config->_config_paths).'config/';
- if (defined('ENVIRONMENT') && file_exists($path.ENVIRONMENT.'/autoload.php'))
+ if (defined('ENVIRONMENT') && file_exists(APPPATH.'config/'.ENVIRONMENT.'/autoload.php'))
{
- include($path.ENVIRONMENT.'/autoload.php');
+ include(APPPATH.'config/'.ENVIRONMENT.'/autoload.php');
}
else
{
- include($path.'autoload.php');
+ include(APPPATH.'config/autoload.php');
}
if ( ! isset($autoload))
@@ -1169,6 +1166,7 @@ class CI_Loader {
// Load any custom config file
if (count($autoload['config']) > 0)
{
+ $CI =& get_instance();
foreach ($autoload['config'] as $key => $val)
{
$CI->config->load($val);
@@ -1277,4 +1275,4 @@ class CI_Loader {
}
/* End of file Loader.php */
-/* Location: ./system/core/Loader.php */
+/* Location: ./system/core/Loader.php */ \ No newline at end of file