Fix improper handling of exceptions on redactions

This commit is contained in:
Frisk 2024-09-06 19:46:45 +02:00
parent 5011659b1d
commit 9fd1cc9904

View file

@ -206,7 +206,7 @@ class Wiki:
for ID in ids:
try:
result.add(all_revids[all_revids.index(ID) + 1])
except (KeyError, ValueError):
except (KeyError, ValueError, IndexError):
logger.debug(f"Value {ID} not in {all_revids} or no value after that.")
return result