Revert part of r60927 which made invalid assumptions about the API offered by db modules.

This commit is contained in:
Raymond Hettinger 2008-02-25 23:17:41 +00:00
parent 9d63837e9b
commit 39df66179f
1 changed files with 3 additions and 3 deletions

View File

@ -95,13 +95,13 @@ class Shelf(UserDict.DictMixin):
return len(self.dict)
def has_key(self, key):
return key in self.dict
return self.dict.has_key(key)
def __contains__(self, key):
return key in self.dict
return self.dict.has_key(key)
def get(self, key, default=None):
if key in self.dict:
if self.dict.has_key(key):
return self[key]
return default