Fix unknown command handling and delete-portal confirmation

This commit is contained in:
Tulir Asokan
2018-02-14 21:56:13 +02:00
parent 1d98e7850f
commit 192f106bfa
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -103,7 +103,7 @@ class CommandHandler:
evt.command = ""
command = sender.command_status["next"]
else:
command = command_handlers["unknown_command"]
command = command_handlers["unknown-command"]
try:
await command(evt)
except FloodWaitError as e:
+1 -1
View File
@@ -101,7 +101,7 @@ async def delete_portal(evt):
that_this = "This" if room_id == evt.room_id else "That"
return await evt.reply(f"{that_this} is not a portal room.")
async def post_confirm(_, confirm):
async def post_confirm(confirm):
evt.sender.command_status = None
if len(confirm.args) > 0 and confirm.args[0] == "confirm-delete":
await portal.cleanup_and_delete()