Log message for revision 78392:
  Only wrap if there's __of__
  

Changed:
  U   Zope/branches/philikon-aq/lib/python/Products/Five/viewlet/manager.py

-=-
Modified: Zope/branches/philikon-aq/lib/python/Products/Five/viewlet/manager.py
===================================================================
--- Zope/branches/philikon-aq/lib/python/Products/Five/viewlet/manager.py       
2007-07-27 21:09:03 UTC (rev 78391)
+++ Zope/branches/philikon-aq/lib/python/Products/Five/viewlet/manager.py       
2007-07-27 21:09:28 UTC (rev 78392)
@@ -65,7 +65,8 @@
         # the object has a real context from which to determine owner
         # security.
         for name, viewlet in viewlets:
-            viewlet = viewlet.__of__(viewlet.context)
+            if getattr(viewlet, '__of__', None) is not None:
+                viewlet = viewlet.__of__(viewlet.__parent__)
             if guarded_hasattr(viewlet, 'render'):
                 results.append((name, viewlet))
         return results

_______________________________________________
Zope-Checkins maillist  -  Zope-Checkins@zope.org
http://mail.zope.org/mailman/listinfo/zope-checkins

Reply via email to