From b82a3e72ff5a1036919dfa1321c99af5042ee66b Mon Sep 17 00:00:00 2001 From: reality Date: Wed, 22 Jul 2015 23:21:56 +0000 Subject: [PATCH] properly resolve unbans --- modules/kick/kick.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/kick/kick.js b/modules/kick/kick.js index b5b919c..5484e4c 100644 --- a/modules/kick/kick.js +++ b/modules/kick/kick.js @@ -91,11 +91,13 @@ var kick = function(dbot) { this.internalAPI = { 'addTempBan': function(server, banee, timeout) { + dbot.api.users.resolveUser(server, dbot.config.name, function(err, bot) { dbot.api.timers.addTimeout(timeout, function() { - this.api.networkUnban(server, banee, dbot.config.name, function(err) {}); + this.api.networkUnban(server, banee, bot, function(err) {}); delete this.tempBans[server][banee]; }.bind(this)); - }.bind(this) + }.bind(this)); + }.bind(this); }; this.listener = function(event) {