Use loop.create_future instead asyncio.Future

This commit is contained in:
Lonami Exo
2018-08-21 12:22:06 +02:00
parent d3a6822fc9
commit fbc46bd388
4 changed files with 5 additions and 5 deletions

View File

@@ -30,7 +30,7 @@ class TLMessage(TLObject):
# If no loop is given then it is an incoming message.
# Only outgoing messages need the future to await them.
self.future = asyncio.Future(loop=loop) if loop else None
self.future = loop.create_future() if loop else None
# After which message ID this one should run. We do this so
# InvokeAfterMsgRequest is transparent to the user and we can