summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2012-07-04 09:35:05 +0200
committerAndrey Andreev <narf@bofh.bg>2012-07-04 09:35:05 +0200
commit474674f8402e3f6198fb2c99a78b6ec2eb80710a (patch)
tree604be34802ae04684737b984637521e8442ca551
parentdd6f32b3b506d29da38f41d307e5ea217c21cb51 (diff)
parentaa141a5e20318608d42e3cda7ebcc0d69fa9b9b8 (diff)
Merge pull request #1571 from cryode/tweak/config
core/Config.php - Moved variable assignment out of loop, other teeny weeny fixes.
-rw-r--r--system/core/Config.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/system/core/Config.php b/system/core/Config.php
index 4b4e5a7ba..2f6a9e085 100644
--- a/system/core/Config.php
+++ b/system/core/Config.php
@@ -43,7 +43,7 @@ class CI_Config {
*
* @var array
*/
- public $config = array();
+ public $config = array();
/**
* List of all loaded config files
@@ -102,13 +102,13 @@ class CI_Config {
{
$file = ($file === '') ? 'config' : str_replace('.php', '', $file);
$found = $loaded = FALSE;
+
+ $check_locations = defined('ENVIRONMENT')
+ ? array(ENVIRONMENT.'/'.$file, $file)
+ : array($file);
foreach ($this->_config_paths as $path)
{
- $check_locations = defined('ENVIRONMENT')
- ? array(ENVIRONMENT.'/'.$file, $file)
- : array($file);
-
foreach ($check_locations as $location)
{
$file_path = $path.'config/'.$location.'.php';
@@ -172,7 +172,7 @@ class CI_Config {
{
return FALSE;
}
- show_error('The configuration file '.$file.'.php'.' does not exist.');
+ show_error('The configuration file '.$file.'.php does not exist.');
}
return TRUE;
@@ -271,7 +271,7 @@ class CI_Config {
*/
public function base_url($uri = '')
{
- return $this->slash_item('base_url').ltrim($this->_uri_string($uri),'/');
+ return $this->slash_item('base_url').ltrim($this->_uri_string($uri), '/');
}
// -------------------------------------------------------------