summaryrefslogtreecommitdiffstats
path: root/system/core/CodeIgniter.php
diff options
context:
space:
mode:
authorAhmad Anbar <aanbar@gmail.com>2015-02-04 18:20:01 +0100
committerAhmad Anbar <aanbar@gmail.com>2015-02-04 18:20:01 +0100
commite5454f9b28f123a5549971f580255a065b2f8cc2 (patch)
treec4927e7b7afb0bf242976034630cc60f2f1db00f /system/core/CodeIgniter.php
parent6db62ab0ad0e223806a1367e12b1884b48dc65d7 (diff)
parenteccac6e6a73a4d1a5b40f383ce64359c2c94ae12 (diff)
Merge remote-tracking branch 'upstream/develop' into develop
Diffstat (limited to 'system/core/CodeIgniter.php')
-rw-r--r--system/core/CodeIgniter.php43
1 files changed, 23 insertions, 20 deletions
diff --git a/system/core/CodeIgniter.php b/system/core/CodeIgniter.php
index 59fdba0e5..d830c1829 100644
--- a/system/core/CodeIgniter.php
+++ b/system/core/CodeIgniter.php
@@ -159,6 +159,29 @@ if ( ! is_php('5.4'))
/*
* ------------------------------------------------------
+ * Should we use a Composer autoloader?
+ * ------------------------------------------------------
+ */
+ if ($composer_autoload = config_item('composer_autoload'))
+ {
+ if ($composer_autoload === TRUE)
+ {
+ file_exists(APPPATH.'vendor/autoload.php')
+ ? require_once(APPPATH.'vendor/autoload.php')
+ : log_message('error', '$config[\'composer_autoload\'] is set to TRUE but '.APPPATH.'vendor/autoload.php was not found.');
+ }
+ elseif (file_exists($composer_autoload))
+ {
+ require_once($composer_autoload);
+ }
+ else
+ {
+ log_message('error', 'Could not find the specified $config[\'composer_autoload\'] path: '.$composer_autoload);
+ }
+ }
+
+/*
+ * ------------------------------------------------------
* Start the timer... tick tock tick tock...
* ------------------------------------------------------
*/
@@ -461,23 +484,6 @@ if ( ! is_php('5.4'))
/*
* ------------------------------------------------------
- * Should we use a Composer autoloader?
- * ------------------------------------------------------
- */
- if ($composer_autoload = config_item('composer_autoload'))
- {
- if ($composer_autoload === TRUE && file_exists(APPPATH.'vendor/autoload.php'))
- {
- require_once(APPPATH.'vendor/autoload.php');
- }
- elseif (file_exists($composer_autoload))
- {
- require_once($composer_autoload);
- }
- }
-
-/*
- * ------------------------------------------------------
* Is there a "pre_controller" hook?
* ------------------------------------------------------
*/
@@ -533,6 +539,3 @@ if ( ! is_php('5.4'))
* ------------------------------------------------------
*/
$EXT->call_hook('post_system');
-
-/* End of file CodeIgniter.php */
-/* Location: ./system/core/CodeIgniter.php */ \ No newline at end of file