[Zope-CVS] CVS: Products/Transience - Transience.py:1.16

Matthew T. Kromer matt@zope.com
Thu, 8 Nov 2001 16:20:42 -0500


Update of /cvs-repository/Products/Transience
In directory cvs.zope.org:/tmp/cvs-serv28218

Modified Files:
	Transience.py 
Log Message:
Make has_key just report success of self.get() with isValid() on success


=== Products/Transience/Transience.py 1.15 => 1.16 ===
     security.declareProtected(ACCESS_TRANSIENTS_PERM, 'has_key')
     def has_key(self, k):
-        self._getCurrentBucket()
-        index = self._ring._index
-        v = index.get(k, _notfound) 
+        v = self.get(k, _notfound) 
         if v is _notfound or not v.isValid(): return 0
         return 1