Browse Source

fix a crashing bug when doing !help ping

master
Jimmy@Jimmy-HP 13 years ago
parent
commit
40f41a9e0b
  1. 1
      modules/common.py
  2. 6
      modules/wolfgame.py

1
modules/common.py

@ -2,6 +2,7 @@ import botconfig @@ -2,6 +2,7 @@ import botconfig
from tools import decorators
import logging
import tools.moduleloader as ld
import traceback
def on_privmsg(cli, rawnick, chan, msg):

6
modules/wolfgame.py

@ -2348,12 +2348,14 @@ def get_help(cli, rnick, rest): @@ -2348,12 +2348,14 @@ def get_help(cli, rnick, rest):
found = True
for fn in c[cname]:
if fn.__doc__:
if nick == botconfig.CHANNEL:
var.LOGGER.logMessage(botconfig.CMD_CHAR+cname+": "+fn.__doc__(rest))
if callable(fn.__doc__):
cli.msg(nick, botconfig.CMD_CHAR+cname+": "+fn.__doc__(rest))
if nick == botconfig.CHANNEL:
var.LOGGER.logMessage(botconfig.CMD_CHAR+cname+": "+fn.__doc__(rest))
else:
cli.msg(nick, botconfig.CMD_CHAR+cname+": "+fn.__doc__)
if nick == botconfig.CHANNEL:
var.LOGGER.logMessage(botconfig.CMD_CHAR+cname+": "+fn.__doc__)
return
else:
continue

Loading…
Cancel
Save