mirror of
https://github.com/eternnoir/pyTelegramBotAPI.git
synced 2023-08-10 21:12:57 +03:00
Merge pull request #266 from Yolley/patch-1
Added isinstance for bytes to function 'add' in ReplyKeyboardMarkup
This commit is contained in:
commit
1058822f85
@ -625,6 +625,8 @@ class ReplyKeyboardMarkup(JsonSerializable):
|
||||
for button in args:
|
||||
if util.is_string(button):
|
||||
row.append({'text': button})
|
||||
elif isinstance(button, bytes):
|
||||
row.append({'text': button.decode('utf-8')})
|
||||
else:
|
||||
row.append(button.to_dic())
|
||||
if i % self.row_width == 0:
|
||||
|
Loading…
Reference in New Issue
Block a user