[Zope3-checkins] CVS: Zope3/src/zope/app/services - folder.py:1.13
Fred L. Drake, Jr.
fred at zope.com
Tue Aug 12 19:00:22 EDT 2003
Update of /cvs-repository/Zope3/src/zope/app/services
In directory cvs.zope.org:/tmp/cvs-serv10077
Modified Files:
folder.py
Log Message:
allow bundles to be added to ++etc++site/
=== Zope3/src/zope/app/services/folder.py 1.12 => 1.13 ===
--- Zope3/src/zope/app/services/folder.py:1.12 Fri Aug 8 17:56:22 2003
+++ Zope3/src/zope/app/services/folder.py Tue Aug 12 18:00:18 2003
@@ -20,6 +20,7 @@
from zope.app.component.nextservice import getNextServiceManager
from zope.app.container.btree import BTreeContainer
+from zope.app.interfaces.services.bundle import IBundle
from zope.app.interfaces.services.folder import ISiteManagementFolders
from zope.app.interfaces.services.folder import ISiteManagementFolder
from zope.app.interfaces.services.service import IComponentManager
@@ -69,7 +70,8 @@
queryComponent = ContextMethod(queryComponent)
def setObject(self, name, obj):
- if not ISiteManagementFolder.isImplementedBy(obj):
+ if not (ISiteManagementFolder.isImplementedBy(obj)
+ or IBundle.isImplementedBy(obj)):
raise TypeError("Can only add packages")
return super(SiteManagementFolders, self).setObject(name, obj)
More information about the Zope3-Checkins
mailing list