diff options
| author | 2018-08-31 12:55:52 +0100 | |
|---|---|---|
| committer | 2018-08-31 13:44:39 +0100 | |
| commit | b7cf524e9869828ff85954cb731f7fee98bee8d9 (patch) | |
| tree | d5d887ac82f3e50f0ea295953981363c1c5e7c5a /modules/seen.py | |
| parent | Revert "Reformat" (diff) | |
| signature | ||
Give modules event objects with "context"s, to facilitate purging all the event
hooks for a module
Diffstat (limited to 'modules/seen.py')
| -rw-r--r-- | modules/seen.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/seen.py b/modules/seen.py index 750b06e4..222d30b5 100644 --- a/modules/seen.py +++ b/modules/seen.py @@ -2,10 +2,10 @@ import time import Utils class Module(object): - def __init__(self, bot): - bot.events.on("received").on("message").on("channel" + def __init__(self, bot, events): + events.on("received").on("message").on("channel" ).hook(self.channel_message) - bot.events.on("received").on("command").on("seen").hook( + events.on("received").on("command").on("seen").hook( self.seen, min_args=1, help="Find out when a user was last seen", usage="<username>") |
