Skip to content
This repository has been archived by the owner on Mar 28, 2019. It is now read-only.

Commit

Permalink
[~TASK] Added function comment to constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
therouv committed May 18, 2012
1 parent 4e9e80f commit c3364a5
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions src/app/code/community/FireGento/GermanSetup/Model/Config.php
Original file line number Diff line number Diff line change
@@ -35,7 +35,13 @@ class FireGento_GermanSetup_Model_Config extends Varien_Simplexml_Config
{
const CACHE_ID = 'germansetup_config';
const CACHE_TAG = 'germansetup_config';


/**
* Sets cache ID and cache tags and loads configuration
*
* @param string|Varien_Simplexml_Element $sourceData
* @return void
*/
public function __construct($sourceData=null)
{
$this->setCacheId(self::CACHE_ID);
@@ -56,10 +62,10 @@ protected function _loadConfig()
return $this;
}
}

$mergeConfig = Mage::getModel('core/config_base');
$config = Mage::getConfig();

// Load additional config files
$configFile = $config->getModuleDir('etc', 'FireGento_GermanSetup') . DS . 'cms.xml';
if (file_exists($configFile)) {
@@ -81,13 +87,12 @@ protected function _loadConfig()
$config->extend($mergeConfig, true);
}
}

$this->setXml($config->getNode());

if (Mage::app()->useCache(self::CACHE_ID)) {
$this->saveCache();
}
return $this;
}
}

}

0 comments on commit c3364a5

Please sign in to comment.