code: async def on_shutdown(app):
      
      # Remove webhook.
      await bot.delete_webhook()
  
      # Close Redis connection.
      await dp.storage.close()
      await dp.storage.wait_closed()
docs: Graceful shutdown. This method is recommended by aiohttp docs.