Commit 1f5ad00d authored by Jens Reidel's avatar Jens Reidel

Add $guild rename

parent e2adf770
Pipeline #2033 canceled with stages
......@@ -331,6 +331,28 @@ class Guild(commands.Cog):
).format(name=name, memberlimit=memberlimit, prefix=ctx.prefix)
@guild.command(brief=_("Renames your guild"))
async def rename(self, ctx, *, new_name: str):
"""`<new_name>` - The new name for the guild.
This renames your guild to something else.
The name may not exceed 20 characters.
Only guild leaders can use this command."""
if len(new_name) > 20:
return await ctx.send(_("Guild names musn't exceed 20 characters."))
'UPDATE guild SET "name"=$1 WHERE "leader"=$2;', new_name,
await ctx.send(
_("Successfully renamed your guild to {new_name}").format(new_name=new_name)
@guild.command(brief=_("Give your guild to someone else"))
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment