We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5419686 commit 7f77552Copy full SHA for 7f77552
1 file changed
Mailman/ListAdmin.py
@@ -205,8 +205,11 @@ def SaveRequestsDb(self):
205
206
def NumRequestsPending(self):
207
self.__opendb()
208
- # Subtract one for the version pseudo-entry
209
- return len(self.__db) - 1
+ if not self.__db:
+ return 0
210
+ # For Python 2 pickles, the version pseudo-entry might not exist
211
+ # Just return the length of the dictionary
212
+ return len(self.__db)
213
214
def __getmsgids(self, rtype):
215
0 commit comments