diff options
author | Andrey Andreev <narf@bofh.bg> | 2013-02-21 15:30:55 +0100 |
---|---|---|
committer | Andrey Andreev <narf@bofh.bg> | 2013-02-21 15:30:55 +0100 |
commit | 49e68de96b420a444c826995746a5f09470e76d9 (patch) | |
tree | c71077bcb4c1bf83971928cec589646ad445343d /system/core/Loader.php | |
parent | 3e01437a5b23d9ffdf1b1cc9fc0a0f8b66551342 (diff) |
Disable autoloader call from class_exists() occurences to improve performance
Note: The Driver libary tests seem to depend on that, so one occurence in CI_Loader is left until we resolve that.
Diffstat (limited to 'system/core/Loader.php')
-rw-r--r-- | system/core/Loader.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/system/core/Loader.php b/system/core/Loader.php index 9306a09ef..6e5b58ba7 100644 --- a/system/core/Loader.php +++ b/system/core/Loader.php @@ -270,7 +270,7 @@ class CI_Loader { continue; } - if ($db_conn !== FALSE && ! class_exists('CI_DB')) + if ($db_conn !== FALSE && ! class_exists('CI_DB', FALSE)) { if ($db_conn === TRUE) { @@ -280,7 +280,7 @@ class CI_Loader { $CI->load->database($db_conn, FALSE, TRUE); } - if ( ! class_exists('CI_Model')) + if ( ! class_exists('CI_Model', FALSE)) { load_class('Model', 'core'); } @@ -1091,11 +1091,11 @@ class CI_Loader { if ($prefix === '') { - if (class_exists('CI_'.$class)) + if (class_exists('CI_'.$class, FALSE)) { $name = 'CI_'.$class; } - elseif (class_exists(config_item('subclass_prefix').$class)) + elseif (class_exists(config_item('subclass_prefix').$class, FALSE)) { $name = config_item('subclass_prefix').$class; } @@ -1110,7 +1110,7 @@ class CI_Loader { } // Is the class name valid? - if ( ! class_exists($name)) + if ( ! class_exists($name, FALSE)) { log_message('error', 'Non-existent class: '.$name); show_error('Non-existent class: '.$name); |