Log message for revision 39473:
  don't fail if caching_policy_manager doesn't exist

Changed:
  U   CMF/trunk/CMFSetup/cachingpolicymgr.py

-=-
Modified: CMF/trunk/CMFSetup/cachingpolicymgr.py
===================================================================
--- CMF/trunk/CMFSetup/cachingpolicymgr.py      2005-10-16 16:35:59 UTC (rev 
39472)
+++ CMF/trunk/CMFSetup/cachingpolicymgr.py      2005-10-16 16:36:25 UTC (rev 
39473)
@@ -63,6 +63,11 @@
     """ Export caching policy manager settings as an XML file.
     """
     site = context.getSite()
+
+    cptool = getToolByName(site, 'caching_policy_manager', None)
+    if cptool is None:
+        return 'Caching policy manager: Nothing to export.'
+
     mhc = CachingPolicyManagerExportConfigurator( site ).__of__( site )
     text = mhc.generateXML()
 
@@ -70,6 +75,7 @@
 
     return 'Caching policy manager settings exported.'
 
+
 class CachingPolicyManagerExportConfigurator(ExportConfiguratorBase):
     """ Synthesize XML description of cc properties.
     """

_______________________________________________
CMF-checkins mailing list
[email protected]
http://mail.zope.org/mailman/listinfo/cmf-checkins

Reply via email to