fixed CallbackQuery.answer() returns nothing (#420)

This commit is contained in:
Oleg A 2020-09-10 22:31:54 +03:00 committed by GitHub
parent 17eb8a56d0
commit 9ab2945267
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -54,8 +54,11 @@ class CallbackQuery(base.TelegramObject):
:type cache_time: :obj:`typing.Union[base.Integer, None]`
:return: On success, True is returned.
:rtype: :obj:`base.Boolean`"""
await self.bot.answer_callback_query(callback_query_id=self.id, text=text,
show_alert=show_alert, url=url, cache_time=cache_time)
return await self.bot.answer_callback_query(callback_query_id=self.id,
text=text,
show_alert=show_alert,
url=url,
cache_time=cache_time)
def __hash__(self):
return hash(self.id)