mirror of
https://gitlab.com/chicken-riders/RcGcDb.git
synced 2025-02-23 00:54:09 +00:00
Ignore the case where the rev-deleted action is an image from teh archive
This commit is contained in:
parent
4c82458ca2
commit
d0f209e6c6
|
@ -695,6 +695,8 @@ async def rc_processor(wiki: Wiki, change: dict, changed_categories: dict, displ
|
|||
logparams = change.get('logparams', {"ids": []})
|
||||
if logparams.get("type", "") == "oldimage":
|
||||
await wiki.redact_images(context, logparams.get("ids", []), logparams.get("new", {}), page_id=change.get("pageid", -1))
|
||||
elif logparams.get("type", "") == "filearchive": # Ignore filearchive (past version of the file gets revdeleted)
|
||||
pass
|
||||
else:
|
||||
await wiki.redact_messages(context, logparams.get("ids", []), "rev_id", logparams.get("new", {}), page_id=change.get("pageid", -1))
|
||||
await wiki.delete_messages(dict(rev_id=[int(x) for x in logparams.get("ids", [])], message_display=0))
|
||||
|
|
Loading…
Reference in a new issue