From d73bd355cf40445e43962caa120e18c99edcc8be Mon Sep 17 00:00:00 2001 From: sgoudham Date: Thu, 23 Jul 2020 15:33:21 +0100 Subject: [PATCH] Adding leave guild --- main.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index 312f7c84..ead9f3bb 100644 --- a/main.py +++ b/main.py @@ -155,10 +155,18 @@ async def on_ready(): @client.command(name="ping", aliases=["Ping"]) async def _ping(ctx): - """Sends the latency of the bot (ms)""" + """Latency of the Bot (ms)""" await ctx.send(f'Pong! `{round(client.latency * 1000)}ms`') +@client.command(name="leave", aliases=["Leave"]) +@is_owner() +async def leave(ctx): + """Leaves the guild""" + await ctx.send("Leaving the guild... Bye Bye uvu") + await leave() + + @client.command(name='help') async def _help(ctx, *, command: str = None): """Shows help about a command or the bot"""