Fix crash on invalid command structure

This commit is contained in:
minerobber 2018-12-15 16:28:15 +00:00
parent 4500d2b4a8
commit 041125e29f
1 changed files with 1 additions and 1 deletions

2
bot.py
View File

@ -30,7 +30,7 @@ class MinerbotPhoenix(teambot.Handler):
try:
plugin.cmds[cmd](self,channel,nick,*args)
except TypeError:
self.say(channel,"Usage: {}{} {}".format(PREFIX,cmd,HELP.get(cmd,"")))
self.say(channel,"Usage: {}{} {}".format(PREFIX,cmd,plugin.help.get(cmd,"")))
except Exception as e:
errcls,err,tb = sys.exc_info()
self.say(channel,"ACCESS VIOLATION: "+traceback.format_exception_only(errcls,err)[0].strip())