mirror of
https://github.com/eternnoir/pyTelegramBotAPI.git
synced 2023-08-10 21:12:57 +03:00
Implemented #17 (with some small adjustments) and ForceReply
Changed apihelper#convert_markup Constructed the Jsonable abstract class. All subclasses must override Jsonable#to_json. Made ReplyKeyboardHide, ReplyKeyboardMarkup and ForceReply a subclass of Jsonable to make things less complicated in convert_markup.
This commit is contained in:
parent
938c98ced1
commit
0068388872
@ -147,7 +147,7 @@ def check_result(func_name, result):
|
|||||||
|
|
||||||
|
|
||||||
def convert_markup(markup):
|
def convert_markup(markup):
|
||||||
if not isinstance(markup, types.Jsonable):
|
if isinstance(markup, types.Jsonable):
|
||||||
return markup.to_json()
|
return markup.to_json()
|
||||||
return markup
|
return markup
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user