3
0
mirror of https://github.com/reality/dbot.git synced 2024-11-23 20:39:25 +01:00

fix up ignore [#131]

This commit is contained in:
reality 2013-01-14 23:02:55 +00:00
parent 7a6cab841e
commit f532aee4ab

View File

@ -72,22 +72,20 @@ var ignore = function(dbot) {
} }
}; };
return { this.name = 'ignore';
'name': 'ignore', this.ignorable = false;
'ignorable': false, this.commands = commands;
'commands': commands,
'onLoad': function() { this.onLoad = function() {
dbot.instance.clearIgnores(); dbot.instance.clearIgnores();
_.each(dbot.db.ignores, function(ignores, user) { _.each(dbot.db.ignores, function(ignores, user) {
_.each(ignores, function(ignore) { _.each(ignores, function(ignore) {
dbot.instance.ignoreTag(user, ignore); dbot.instance.ignoreTag(user, ignore);
}, this);
}, this); }, this);
} }, this);
}; };
}; };
exports.fetch = function(dbot) { exports.fetch = function(dbot) {
return ignore(dbot); return new ignore(dbot);
}; };