[z3-checkins] r18408 - z3/Five/branch/regebro-sitemanager

regebro at codespeak.net regebro at codespeak.net
Tue Oct 11 16:45:05 CEST 2005


Author: regebro
Date: Tue Oct 11 16:45:04 2005
New Revision: 18408

Modified:
   z3/Five/branch/regebro-sitemanager/fiveconfigure.py
Log:
Also sprach philiKON: Use minus.



Modified: z3/Five/branch/regebro-sitemanager/fiveconfigure.py
==============================================================================
--- z3/Five/branch/regebro-sitemanager/fiveconfigure.py	(original)
+++ z3/Five/branch/regebro-sitemanager/fiveconfigure.py	Tue Oct 11 16:45:04 2005
@@ -25,7 +25,7 @@
 import App
 from zLOG import LOG, ERROR
 
-from zope.interface import classImplements
+from zope.interface import classImplements, classImplementsOnly, implementedBy
 from zope.interface.interface import InterfaceClass
 from zope.configuration import xmlconfig
 from zope.configuration.exceptions import ConfigurationError
@@ -328,10 +328,7 @@
 def uinstallSiteHook(class_):
     delattr(class_, 'getSiteManager')
     delattr(class_, 'setSiteManager')
-    from zope.interface import implementedBy, classImplementsOnly
-    ifaces = list(implementedBy(class_).interfaces())
-    ifaces = [i for i in ifaces if i is not ISite]
-    classImplementsOnly(class_, ifaces)
+    classImplementsOnly(class_, implementedBy(class_)-ISite)
     _localsite_monkies.remove(class_)
 
 def cleanUp():


More information about the z3-checkins mailing list