Skip to content

Commit 81c973d

Browse files
author
Richard Jones
committed
fix bug exposed by earlier change to defaulting of *dbm property values
1 parent 363f984 commit 81c973d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

roundup/backends/back_anydbm.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
1616
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
1717
#
18-
#$Id: back_anydbm.py,v 1.163 2004-07-20 22:56:18 richard Exp $
18+
#$Id: back_anydbm.py,v 1.164 2004-07-21 00:51:21 richard Exp $
1919
'''This module defines a backend that saves the hyperdatabase in a
2020
database chosen by anydbm. It is guaranteed to always be available in python
2121
versions >2.1.1 (the dumbdbm fallback in 2.1.1 and earlier has several
@@ -1383,6 +1383,8 @@ def lookup(self, keyvalue):
13831383
node = self.db.getnode(self.classname, nodeid, cldb)
13841384
if node.has_key(self.db.RETIRED_FLAG):
13851385
continue
1386+
if not node.has_key(self.key):
1387+
continue
13861388
if node[self.key] == keyvalue:
13871389
return nodeid
13881390
finally:

0 commit comments

Comments
 (0)