[Erp5-report] r29639 - /erp5/trunk/products/ERP5Type/Tool/CacheTool.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Wed Oct 14 11:46:15 CEST 2009
Author: nicolas
Date: Wed Oct 14 11:46:13 2009
New Revision: 29639
URL: http://svn.erp5.org?rev=29639&view=rev
Log:
revert r29556, this "if" condition exists to avoid instanciation of CacheFactory without cache plugins
Modified:
erp5/trunk/products/ERP5Type/Tool/CacheTool.py
Modified: erp5/trunk/products/ERP5Type/Tool/CacheTool.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Type/Tool/CacheTool.py?rev=29639&r1=29638&r2=29639&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Type/Tool/CacheTool.py [utf8] (original)
+++ erp5/trunk/products/ERP5Type/Tool/CacheTool.py [utf8] Wed Oct 14 11:46:13 2009
@@ -118,10 +118,12 @@
CachingMethod.factories = {}
## read configuration from ZODB
for key, item in self.getCacheFactoryList().items():
- ## init cache backend storages
- for cp in item["cache_plugins"]:
- cp.initCacheStorage()
- CachingMethod.factories[key] = CacheFactory(item['cache_plugins'], item['cache_params'])
+ #If there is no cache_plugins, do not create Cache Factory
+ if item["cache_plugins"]:
+ ## init cache backend storages
+ for cp in item["cache_plugins"]:
+ cp.initCacheStorage()
+ CachingMethod.factories[key] = CacheFactory(item['cache_plugins'], item['cache_params'])
if REQUEST is not None:
self.REQUEST.RESPONSE.redirect('cache_tool_configure?manage_tabs_message=Cache updated.')
More information about the Erp5-report
mailing list