diff --git a/lib/channel/chat.js b/lib/channel/chat.js index 57f839e0..5cfa0c1c 100644 --- a/lib/channel/chat.js +++ b/lib/channel/chat.js @@ -162,6 +162,15 @@ ChatModule.prototype.handlePm = function (user, data) { }); } + if (data.msg.match(Config.get("link-domain-blacklist-regex"))) { + this.channel.logger.log(user.displayip + " (" + user.getName() + ") was kicked for " + + "blacklisted domain"); + user.kick(); + this.sendModMessage(user.getName() + " was kicked: blacklisted domain in " + + "private message", 2); + return; + } + var reallyTo = data.to; data.to = data.to.toLowerCase();