mirror of
https://github.com/pyrogram/pyrogram
synced 2025-08-28 12:57:52 +00:00
Automatically coerce any text to string for keyboard buttons
This commit is contained in:
parent
b0c011c70c
commit
5294c21e97
@ -63,7 +63,7 @@ class InlineKeyboardButton(PyrogramType):
|
||||
callback_game: CallbackGame = None):
|
||||
super().__init__(None)
|
||||
|
||||
self.text = text
|
||||
self.text = str(text)
|
||||
self.url = url
|
||||
self.callback_data = callback_data
|
||||
self.switch_inline_query = switch_inline_query
|
||||
|
@ -46,7 +46,7 @@ class KeyboardButton(PyrogramType):
|
||||
request_location: bool = None):
|
||||
super().__init__(None)
|
||||
|
||||
self.text = text
|
||||
self.text = str(text)
|
||||
self.request_contact = request_contact
|
||||
self.request_location = request_location
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user