From 1c6da84679831b5890542dbc095c3669b8a5d023 Mon Sep 17 00:00:00 2001 From: sfan5 Date: Sun, 30 Jun 2024 18:23:50 +0200 Subject: [PATCH] Add message effect to karma notifications kinda stupid but okay --- secretlounge_ng/telegram.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/secretlounge_ng/telegram.py b/secretlounge_ng/telegram.py index 01d12b5..b4c4767 100644 --- a/secretlounge_ng/telegram.py +++ b/secretlounge_ng/telegram.py @@ -416,6 +416,8 @@ def send_to_single_inner(chat_id, ev, reply_to=None, force_caption=None): kwargs2["reply_parameters"] = reply_parameters(reply_to) if ev.type == rp.types.CUSTOM: kwargs2["link_preview_options"] = telebot.types.LinkPreviewOptions(is_disabled=True) + elif ev.type == rp.types.KARMA_NOTIFICATION: + kwargs2["message_effect_id"] = "5107584321108051014" # thumbs up kwargs2["parse_mode"] = "HTML" return bot.send_message(chat_id, rp.formatForTelegram(ev), **kwargs2) elif isinstance(ev, FormattedMessage):