diff options
author | Greg Aker <greg@gregaker.net> | 2011-12-27 23:23:47 +0100 |
---|---|---|
committer | Greg Aker <greg@gregaker.net> | 2011-12-27 23:23:47 +0100 |
commit | d96f88277c1e9a4c069c2e2ee3d779385549f31a (patch) | |
tree | 5d3f9fb534ca9fa17635ddcd8c3d38abe51deec2 /system/core/Hooks.php | |
parent | d459cbb96d9c9703ef6c62756240b7c612835e5c (diff) |
Revert "Abstracting the loading of files in the config directory depending on environments."
This reverts commit 5c1aa631c5f5ec2f6b75ba1158178418e50ba11a.
Diffstat (limited to 'system/core/Hooks.php')
-rwxr-xr-x | system/core/Hooks.php | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/system/core/Hooks.php b/system/core/Hooks.php index 6a36ce963..aa251a389 100755 --- a/system/core/Hooks.php +++ b/system/core/Hooks.php @@ -91,7 +91,16 @@ class CI_Hooks { // Grab the "hooks" definition file. // If there are no hooks, we're done. - load_environ_config('hooks'); + + if (defined('ENVIRONMENT') AND is_file(APPPATH.'config/'.ENVIRONMENT.'/hooks.php')) + { + include(APPPATH.'config/'.ENVIRONMENT.'/hooks.php'); + } + elseif (is_file(APPPATH.'config/hooks.php')) + { + include(APPPATH.'config/hooks.php'); + } + if ( ! isset($hook) OR ! is_array($hook)) { |