mirror of
https://github.com/python/cpython.git
synced 2025-10-07 15:42:02 +00:00
fix stupid bug (db should be dict)
This commit is contained in:
parent
780620f2fd
commit
cebfa70a79
1 changed files with 3 additions and 3 deletions
|
@ -65,9 +65,9 @@ class Shelf:
|
||||||
del self.dict[key]
|
del self.dict[key]
|
||||||
|
|
||||||
def close(self):
|
def close(self):
|
||||||
if hasattr(self.db, 'close'):
|
if hasattr(self.dict, 'close'):
|
||||||
self.db.close()
|
self.dict.close()
|
||||||
self.db = None
|
self.dict = None
|
||||||
|
|
||||||
def __del__(self):
|
def __del__(self):
|
||||||
self.close()
|
self.close()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue