Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormatt <matt@59fd770c-687e-43c8-a1e3-f5a4ff64c105>2009-05-12 01:39:02 +0400
committermatt <matt@59fd770c-687e-43c8-a1e3-f5a4ff64c105>2009-05-12 01:39:02 +0400
commit0a0637ba8a326b957fee6277a8c08bb6ab7d7375 (patch)
treedfb5da0ba6a6f0eb07afe3b85258ba38a313c3e7
parentfb483ef6714e6b0ab88d1ba3fd01cc56083acce1 (diff)
fixing installation config error
-rw-r--r--core/Config.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/core/Config.php b/core/Config.php
index 39d3e7bea1..57e7cdafc1 100644
--- a/core/Config.php
+++ b/core/Config.php
@@ -39,6 +39,7 @@ class Piwik_Config
protected $pathIniFileDefaultConfig = null;
protected $configFileUpdated = false;
protected $doWriteFileWhenUpdated = true;
+ protected $cachedConfigArray = array();
/**
* Storing the correct cwd() because the value is not correct in the destructor
@@ -108,8 +109,8 @@ class Piwik_Config
throw new Exception("The configuration file {$this->pathIniFileUserConfig} has not been found.");
}
$this->userConfig = new Zend_Config_Ini($this->pathIniFileUserConfig, null, true);
-
}
+
/**
* At the script shutdown, we save the new configuration file, if the user has set some values
*/
@@ -195,7 +196,6 @@ class Piwik_Config
protected function checkWritePermissionOnFile()
{
static $enoughPermission = null;
-
if(is_null($enoughPermission))
{
if($this->doWriteFileWhenUpdated)
@@ -207,8 +207,6 @@ class Piwik_Config
return $enoughPermission;
}
- protected $cachedConfigArray = array();
-
/**
* Loop through the Default and the User configuration objects and cache them in arrays.
* This slightly helps reducing the Zend overhead when accessing config entries hundreds of times.
@@ -221,9 +219,12 @@ class Piwik_Config
{
$allSections[] = $sectionName;
}
- foreach($this->userConfig as $sectionName => $valueInUserConfig)
+ if(!is_null($this->userConfig))
{
- $allSections[] = $sectionName;
+ foreach($this->userConfig as $sectionName => $valueInUserConfig)
+ {
+ $allSections[] = $sectionName;
+ }
}
$allSections = array_unique($allSections);