diff options
author | Jon Bergli Heier <snakebite@jvnv.net> | 2010-05-26 18:38:52 +0200 |
---|---|---|
committer | Jon Bergli Heier <snakebite@jvnv.net> | 2010-05-26 18:38:52 +0200 |
commit | dec939c32f5f4de366a8f72eaa85fbc827996041 (patch) | |
tree | 932fdcfc5394df46dbf1fd82f8bdbccff8e52d25 /modules | |
parent | c23d205928499b578e0742363dbfd8dc0116f394 (diff) |
Added privmsg callback.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/url_titles.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/url_titles.py b/modules/url_titles.py index d5408ce..3172fac 100644 --- a/modules/url_titles.py +++ b/modules/url_titles.py @@ -15,6 +15,7 @@ class Module: def __init__(self, bot): self.irc = bot + self.irc.register_callback(self) def spotify(self, s): try: @@ -137,7 +138,7 @@ class Module: s += '\002[%d]\002 %s ' % (i+1, format_text(titles[i])) return s.strip() - def __call__(self, nick, channel, msg): + def privmsg(self, nick, channel, msg): titles = self.get_titles(msg) if titles: self.irc.msg(channel if not channel == self.irc.nickname else nick.split('!')[0], titles) |