From: <gem...@li...> - 2011-11-07 13:48:41
|
Revision: 187 http://gemstracker.svn.sourceforge.net/gemstracker/?rev=187&view=rev Author: michieltcs Date: 2011-11-07 13:48:32 +0000 (Mon, 07 Nov 2011) Log Message: ----------- Allow creation of (dummy) cache when cache directory is not writeable Modified Paths: -------------- trunk/library/classes/GemsEscort.php Modified: trunk/library/classes/GemsEscort.php =================================================================== --- trunk/library/classes/GemsEscort.php 2011-11-07 09:26:56 UTC (rev 186) +++ trunk/library/classes/GemsEscort.php 2011-11-07 13:48:32 UTC (rev 187) @@ -170,11 +170,13 @@ 'cache_id_prefix' => GEMS_PROJECT_NAME . '_'); $cache = Zend_Cache::factory('Core', $cacheBackend, $cacheFrontendOptions, $cacheBackendOptions); - - Zend_Db_Table_Abstract::setDefaultMetadataCache($cache); - Zend_Translate::setCache($cache); + } else { + $cache = Zend_Cache::factory('Core', 'Static', array('caching' => false), array('disable_caching' => true)); } + Zend_Db_Table_Abstract::setDefaultMetadataCache($cache); + Zend_Translate::setCache($cache); + return $cache; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |