[Zope-Checkins] CVS: Zope/lib/python/AccessControl - Owned.py:1.15.10.2
Matthew T. Kromer
matt@zope.com
Fri, 1 Mar 2002 15:33:39 -0500
Update of /cvs-repository/Zope/lib/python/AccessControl
In directory cvs.zope.org:/tmp/cvs-serv7071
Modified Files:
Tag: Zope-2_5-branch
Owned.py
Log Message:
Remove caching from getOwner since cached objects should not be wrapped,
and both wrapped and unwrapped objects would have otherwise been cached.
=== Zope/lib/python/AccessControl/Owned.py 1.15.10.1 => 1.15.10.2 ===
udb, oid = owner
- upath = ('',) + tuple(udb) + (oid,)
- objectCache = getSecurityManager()._context.objectCache
- if objectCache.has_key(upath):
- return objectCache[upath]
root=self.getPhysicalRoot()
udb=root.unrestrictedTraverse(udb, None)
@@ -97,7 +93,6 @@
if not hasattr(user, 'aq_parent'):
user = user.__of__(udb)
- objectCache[upath] = user
return user
changeOwnership__roles__=()