Update dispatcher.py

This commit is contained in:
Aryn 2023-08-02 18:10:25 +06:00 committed by GitHub
parent 40621eb494
commit 81852cdda2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -546,7 +546,7 @@ class Dispatcher(Router):
finally:
loggers.dispatcher.info("Polling stopped")
try:
await self.emit_shutdown(bot=bots[-1], **workflow_data)
await self.emit_shutdown(bots[-1], **workflow_data)
finally:
if close_bot_session:
await asyncio.gather(*(bot.session.close() for bot in bots))