From 42a7c54c0a2d634018199944cd58cad3992cc39d Mon Sep 17 00:00:00 2001 From: Pavel Djundik Date: Sun, 6 Mar 2016 11:04:58 +0200 Subject: [PATCH] Fix #153: Do not intercept service commands --- src/client.js | 1 - src/plugins/inputs/services.js | 26 -------------------------- 2 files changed, 27 deletions(-) delete mode 100644 src/plugins/inputs/services.js diff --git a/src/client.js b/src/client.js index 82f0bccd..6dff0800 100644 --- a/src/client.js +++ b/src/client.js @@ -45,7 +45,6 @@ var inputs = [ "part", "quit", "raw", - "services", "topic", "whois" ]; diff --git a/src/plugins/inputs/services.js b/src/plugins/inputs/services.js deleted file mode 100644 index 6c0db36d..00000000 --- a/src/plugins/inputs/services.js +++ /dev/null @@ -1,26 +0,0 @@ -var _ = require("lodash"); - -module.exports = function(network, chan, cmd, args) { - if (cmd !== "ns" && cmd !== "cs" && cmd !== "hs") { - return; - } - var target = ({ - "ns": "nickserv", - "cs": "chanserv", - "hs": "hostserv", - })[cmd]; - if (!target || args.length === 0 || args[0] === "") { - return; - } - var irc = network.irc; - var msg = args.join(" "); - irc.send(target, msg); - var channel = _.find(network.channels, {name: target}); - if (typeof channel !== "undefined") { - irc.emit("message", { - from: irc.me, - to: channel.name, - message: msg - }); - } -};