From fc6816226329ebdf3c96279c166783061cc970b4 Mon Sep 17 00:00:00 2001 From: KurimuzonAkuma Date: Tue, 27 Aug 2024 13:33:18 +0300 Subject: [PATCH] Fix inline_message_id for ChosenInlineResultHandler pyrogram/pyrogram#1345 --- .../types/inline_mode/chosen_inline_result.py | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/pyrogram/types/inline_mode/chosen_inline_result.py b/pyrogram/types/inline_mode/chosen_inline_result.py index 623d7379..da2d6f9b 100644 --- a/pyrogram/types/inline_mode/chosen_inline_result.py +++ b/pyrogram/types/inline_mode/chosen_inline_result.py @@ -16,12 +16,10 @@ # You should have received a copy of the GNU Lesser General Public License # along with Pyrogram. If not, see . -from base64 import b64encode -from struct import pack - import pyrogram from pyrogram import raw from pyrogram import types +from pyrogram import utils from ..object import Object from ..update import Update @@ -73,18 +71,9 @@ class ChosenInlineResult(Object, Update): @staticmethod def _parse(client, chosen_inline_result: raw.types.UpdateBotInlineSend, users) -> "ChosenInlineResult": - inline_message_id = None - - if isinstance(chosen_inline_result.msg_id, raw.types.InputBotInlineMessageID): - inline_message_id = b64encode( - pack( - "