mirror of
https://gitlab.com/chicken-riders/RcGcDb.git
synced 2025-02-23 00:54:09 +00:00
fix thank button for logs
This commit is contained in:
parent
c96488153c
commit
faf3d3d9eb
|
@ -66,13 +66,11 @@ def buttons_hook(message: DiscordMessage, metadata: DiscordMessageMetadata, cont
|
|||
if "move" in action_buttons and context.event in ("move/move", "move/move_redir"):
|
||||
add_button(message, BUTTON_PREFIX + " move " + str(change["pageid"]) + " " + change["title"],
|
||||
context.gettext("Move back"), 2, {"id": None, "name": "🔂"})
|
||||
if context.event != "edit":
|
||||
return
|
||||
if "rollback" in action_buttons:
|
||||
if "rollback" in action_buttons and context.event == "edit":
|
||||
add_button(message, BUTTON_PREFIX + " rollback " + str(change["pageid"]) + " " + (
|
||||
"#" + str(change["userid"]) if change["userid"] else change["user"]),
|
||||
context.gettext("Rollback"), 1, {"id": None, "name": "🔁"})
|
||||
if "undo" in action_buttons:
|
||||
if "undo" in action_buttons and context.event == "edit":
|
||||
add_button(message, BUTTON_PREFIX + " undo " + str(change["pageid"]) + " " + str(change["revid"]),
|
||||
context.gettext("Undo"), 2, {"id": None, "name": "🔂"})
|
||||
if "thank" in action_buttons and context.event != "suppressed":
|
||||
|
|
Loading…
Reference in a new issue