fixed assignowner, finally
This commit is contained in:
parent
b6f776d7cb
commit
214b05c09d
|
@ -549,12 +549,13 @@ class AssignOwnerCommand(Command):
|
||||||
return user.id in config()["owners"]
|
return user.id in config()["owners"]
|
||||||
|
|
||||||
async def execute(self, msg, command):
|
async def execute(self, msg, command):
|
||||||
new_owner = msg.mentions[0]
|
if isauthorized(msg.author):
|
||||||
team_name = command.strip().split(new_owner.mention+" ")[1]
|
new_owner = msg.mentions[0]
|
||||||
if db.assign_owner(team_name, new_owner.id):
|
team_name = command.strip().split("> ",1)[1]
|
||||||
await msg.channel.send(f"{team_name} is now owned by {new_owner.display_name}. Don't break it.")
|
if db.assign_owner(team_name, new_owner.id):
|
||||||
else:
|
await msg.channel.send(f"{team_name} is now owned by {new_owner.display_name}. Don't break it.")
|
||||||
await msg.channel.send("We couldn't find that team. Typo?")
|
else:
|
||||||
|
await msg.channel.send("We couldn't find that team. Typo?")
|
||||||
|
|
||||||
class StartTournamentCommand(Command):
|
class StartTournamentCommand(Command):
|
||||||
name = "starttournament"
|
name = "starttournament"
|
||||||
|
|
Loading…
Reference in a new issue