forgot embed formatter

This commit is contained in:
MarkusRost 2024-07-05 21:51:43 +00:00
parent ce80e15b36
commit cfa01a2613

View file

@ -1196,6 +1196,11 @@ async def embed_formatter(action, change, parsed_comment, categories, recent_cha
embed.add_field(_("Report this on the support server"), settings["support"])
else:
embed.add_field(_("Report this on the support server"), change_params)
if "thank" in action_buttons and action != "suppressed":
if change["type"] == "log":
embed.add_button(BUTTON_PREFIX + " thank log " + str(change["logid"]), _("Thank user"), 3, {"id": None, "name": "👍"})
else:
embed.add_button(BUTTON_PREFIX + " thank rev " + str(change["revid"]), _("Thank user"), 3, {"id": None, "name": "👍"})
embed["url"] = link
if parsed_comment is not None:
embed["description"] = parsed_comment