Fix crash on invalid command structure
This commit is contained in:
parent
4500d2b4a8
commit
041125e29f
2
bot.py
2
bot.py
|
@ -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())
|
||||
|
|
Loading…
Reference in New Issue