From beffcd5db8c2bd01812f048a175daeeb4442c72a Mon Sep 17 00:00:00 2001 From: Bert Belder Date: Fri, 3 Aug 2012 01:07:44 +0200 Subject: [PATCH] Make parsing authentication commands work correctly --- logger.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/logger.js b/logger.js index d4ec12d..2186e7b 100644 --- a/logger.js +++ b/logger.js @@ -30,9 +30,9 @@ function getIrcClient(server, nick, auth) { for (var i = 0; i < auth.length; i++) { var command = auth[i], result; - if ((result = command.match(/^\/msg\s+(\S+)\s+(.*)$/i))) { + if ((result = command.match(/^\/msg\s+(\S+)\s+(.*)/i))) { client.say(result[1], result[2]); - } else { + } else if (/S/.test(command)) { throw new Error("Unknown auth command:" + command); } }