how to make my discord bot shut down with a command

Solutions on MaxInterview for how to make my discord bot shut down with a command by the best coders in the world

we are a community of more than 2 million smartest coders
registration for
employee referral programs
are now open
get referred to google, amazon, flipkart and more
register now
  
pinned-register now
showing results for - "how to make my discord bot shut down with a command"
Yannik
23 May 2018
1#this was in a cog
2@commands.command()
3@commands.is_owner()
4  async def shutdown(self, ctx):
5     await ctx.bot.logout()