mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-27 21:19:31 +01:00
Irc: log unrecognized commands to INFO too
This commit is contained in:
parent
2bf9568fbb
commit
e4cfd1e1e6
@ -178,11 +178,13 @@ class Irc():
|
|||||||
return
|
return
|
||||||
|
|
||||||
def callCommand(self, source, text):
|
def callCommand(self, source, text):
|
||||||
|
"""Calls a PyLink bot command."""
|
||||||
cmd_args = text.strip().split(' ')
|
cmd_args = text.strip().split(' ')
|
||||||
cmd = cmd_args[0].lower()
|
cmd = cmd_args[0].lower()
|
||||||
cmd_args = cmd_args[1:]
|
cmd_args = cmd_args[1:]
|
||||||
if cmd not in world.commands:
|
if cmd not in world.commands:
|
||||||
self.msg(self.called_by or source, 'Error: Unknown command %r.' % cmd)
|
self.msg(self.called_by or source, 'Error: Unknown command %r.' % cmd)
|
||||||
|
log.info('(%s) Received unknown command %r from %s', self.name, cmd, utils.getHostmask(self, source))
|
||||||
return
|
return
|
||||||
log.info('(%s) Calling command %r for %s', self.name, cmd, utils.getHostmask(self, source))
|
log.info('(%s) Calling command %r for %s', self.name, cmd, utils.getHostmask(self, source))
|
||||||
for func in world.commands[cmd]:
|
for func in world.commands[cmd]:
|
||||||
|
Loading…
Reference in New Issue
Block a user