[Checkins] SVN: Zope/trunk/src/OFS/metaconfigure.py Make the	cleanup code more fail-safe
    Hanno Schlichting 
    hannosch at hannosch.eu
       
    Thu Aug  5 14:29:41 EDT 2010
    
    
  
Log message for revision 115506:
  Make the cleanup code more fail-safe
Changed:
  U   Zope/trunk/src/OFS/metaconfigure.py
-=-
Modified: Zope/trunk/src/OFS/metaconfigure.py
===================================================================
--- Zope/trunk/src/OFS/metaconfigure.py	2010-08-05 18:19:36 UTC (rev 115505)
+++ Zope/trunk/src/OFS/metaconfigure.py	2010-08-05 18:29:40 UTC (rev 115506)
@@ -199,8 +199,9 @@
     _registered_packages = []
 
     global _meta_type_regs
-    Products.meta_types = tuple([ info for info in Products.meta_types
-                                  if info['name'] not in _meta_type_regs ])
+    old = getattr(Products, 'meta_types', ())
+    new = tuple([info for info in old if info['name'] not in _meta_type_regs])
+    setattr(Products, 'meta_types', new)
     _meta_type_regs = []
 
 
    
    
More information about the checkins
mailing list