1
0
mirror of https://github.com/eternnoir/pyTelegramBotAPI.git synced 2023-08-10 21:12:57 +03:00
This commit is contained in:
coder2020official 2021-07-30 19:15:37 +05:00
parent 7ebe589b46
commit 81adfd335e
2 changed files with 2 additions and 2 deletions

View File

@ -2132,7 +2132,7 @@ class TeleBot:
parse_mode = self.parse_mode if (parse_mode is None) else parse_mode parse_mode = self.parse_mode if (parse_mode is None) else parse_mode
result = apihelper.edit_message_caption(self.token, caption, chat_id, message_id, inline_message_id, result = apihelper.edit_message_caption(self.token, caption, chat_id, message_id, inline_message_id,
parse_mode, reply_markup) parse_mode, caption_entities, reply_markup)
if type(result) == bool: if type(result) == bool:
return result return result
return types.Message.de_json(result) return types.Message.de_json(result)

View File

@ -1135,7 +1135,7 @@ def edit_message_caption(token, caption, chat_id=None, message_id=None, inline_m
if parse_mode: if parse_mode:
payload['parse_mode'] = parse_mode payload['parse_mode'] = parse_mode
if caption_entities: if caption_entities:
payload['caption_entities'] = caption_entities payload['caption_entities'] = json.dumps(types.MessageEntity.to_list_of_dicts(caption_entities))
if reply_markup: if reply_markup:
payload['reply_markup'] = _convert_markup(reply_markup) payload['reply_markup'] = _convert_markup(reply_markup)
return _make_request(token, method_url, params=payload, method='post') return _make_request(token, method_url, params=payload, method='post')