for arg in args:
if arg[0] != "-":
if module is not None:
- bot.msg(user, "Wrong number of arguments.")
+ bot.msg(user, "Incorrect syntax - can only name one module")
return
module = arg
- elif arg == "-autoload":
+ elif arg.lower() == "-autoload":
autoload = True
- elif arg == "-force":
+ elif arg.lower() == "-force":
force = True
else:
bot.msg(user, "Bad option %s" % (arg))
return
if len(ctlmod.dependents[module]) > 0:
if not force:
- bot.msg(user, "That module has dependents! Say MODUNLOAD %s FORCE to unload it and any dependents." % (module))
+ bot.msg(user, "That module has dependents! Say MODUNLOAD -force %s to unload it and any dependents." % (module))
return
okay = ctlmod.unload(bot.parent, module)