[Zope-Checkins] SVN: Zope/branches/2.13/src/OFS/Traversable.py Move NullResource to normal module scope import
Hanno Schlichting
hannosch at hannosch.eu
Sat Aug 20 12:21:56 EDT 2011
Log message for revision 122634:
Move NullResource to normal module scope import
Changed:
U Zope/branches/2.13/src/OFS/Traversable.py
-=-
Modified: Zope/branches/2.13/src/OFS/Traversable.py
===================================================================
--- Zope/branches/2.13/src/OFS/Traversable.py 2011-08-20 16:11:34 UTC (rev 122633)
+++ Zope/branches/2.13/src/OFS/Traversable.py 2011-08-20 16:21:56 UTC (rev 122634)
@@ -27,6 +27,7 @@
from Acquisition import aq_parent
from Acquisition.interfaces import IAcquirer
from OFS.interfaces import ITraversable
+from webdav.NullResource import NullResource
from zExceptions import NotFound
from ZPublisher.interfaces import UseTraversalDefault
from ZODB.POSException import ConflictError
@@ -39,7 +40,6 @@
from zope.traversing.namespace import nsParse
_marker = object()
-NullResource = None
class Traversable:
@@ -254,10 +254,6 @@
# The item lookup may return a NullResource,
# if this is the case we save it and return it
# if all other lookups fail.
- global NullResource
- if NullResource is None:
- from webdav.NullResource import NullResource
-
if isinstance(next, NullResource):
resource = next
raise KeyError(name)
More information about the Zope-Checkins
mailing list