[Checkins] SVN: Products.GenericSetup/branches/1.3/Products/GenericSetup/components.py Five.lsm wraps all utilities - try to deal with that

Wichert Akkerman wichert at wiggy.net
Sun Dec 16 09:32:26 EST 2007


Log message for revision 82299:
  Five.lsm wraps all utilities - try to deal with that

Changed:
  U   Products.GenericSetup/branches/1.3/Products/GenericSetup/components.py

-=-
Modified: Products.GenericSetup/branches/1.3/Products/GenericSetup/components.py
===================================================================
--- Products.GenericSetup/branches/1.3/Products/GenericSetup/components.py	2007-12-16 06:34:19 UTC (rev 82298)
+++ Products.GenericSetup/branches/1.3/Products/GenericSetup/components.py	2007-12-16 14:32:25 UTC (rev 82299)
@@ -221,8 +221,12 @@
             if getattr(comp, 'aq_base', None) is not None:
                 if aq_base(comp) is site:
                     child.setAttribute('object', '')
+                elif hasattr(aq_base(comp, 'getId')):
+                    child.setAttribute('object', comp.getId())
                 else:
-                    child.setAttribute('object', comp.getId())
+                    # This is a five.localsitemanager wrapped utility
+                    factory = _getDottedName(type(aq_base(comp)))
+                    child.setAttribute('factory', factory)
             else:
                 factory = _getDottedName(type(comp))
                 child.setAttribute('factory', factory)



More information about the Checkins mailing list