Alias module replace aliases only in PRIVMSG

This commit is contained in:
Némunaire 2012-11-05 12:00:24 +01:00
parent cf249d1592
commit dda1b706c7

View File

@ -113,7 +113,7 @@ def treat_variables(res):
return True
def treat_alias(msg, hooks_cache):
if (len(msg.cmds[0]) > 0 and
if msg.cmd == "PRIVMSG" and (len(msg.cmds[0]) > 0 and
msg.cmds[0][1:] in DATAS.getNode("aliases").index and
msg.cmds[0][1:] not in hooks_cache("cmd_hook")):
msg.content = msg.content.replace(msg.cmds[0],