1
Fork 0
mirror of https://github.com/RYGhub/royalnet.git synced 2024-11-27 13:34:28 +00:00

Added a method to the Message object

This commit is contained in:
Steffo 2017-03-09 12:52:06 +01:00
parent f583072edc
commit 40403f9d1a

View file

@ -1,5 +1,4 @@
import asyncio
loop = asyncio.get_event_loop()
import aiohttp
import async_timeout
@ -343,9 +342,9 @@ class Message:
else:
return f"<Message containing {type(self.content)}>"
def reply(self, bot, text, **params):
async def reply(self, bot, text, **params):
"""Reply to this message."""
self.chat.send_message(bot, text, reply_to_message_id=self.msg_id, **params)
await self.chat.send_message(bot, text, reply_to_message_id=self.msg_id, **params)
class ServiceMessage:
def __init__(self, msg_type, extra=None):