If no person is specified, then the mode changed on the channel

This commit is contained in:
Chris Oliver 2011-09-23 17:13:44 -05:00
parent 0460e401b7
commit 4f08a04e17

View file

@ -282,7 +282,7 @@ class Logbot(SingleServerIRCBot):
def on_mode(self, c, e):
self.write_event("mode", e,
{"%modes%" : e.arguments()[0],
"%person%" : e.arguments()[1] if len(e.arguments()) > 1 else "",
"%person%" : e.arguments()[1] if len(e.arguments()) > 1 else e.target(),
"%giver%" : nm_to_n(e.source()),
})