From 73572b0839db506621c2babf9b6fafb527c65da6 Mon Sep 17 00:00:00 2001 From: Alex Kocharin Date: Wed, 18 Jun 2014 04:52:07 +0400 Subject: [PATCH] fix #77, config assert() has no effect --- lib/config.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/config.js b/lib/config.js index 9efca141e..593518b3d 100644 --- a/lib/config.js +++ b/lib/config.js @@ -30,7 +30,7 @@ function Config(config) { var users = {all:true, anonymous:true, 'undefined':true, owner:true, none:true} var check_user_or_uplink = function(arg) { - assert(arg !== 'all' || arg !== 'owner' || arg !== 'anonymous' || arg !== 'undefined' || arg !== 'none', 'CONFIG: reserved user/uplink name: ' + arg) + assert(arg !== 'all' && arg !== 'owner' && arg !== 'anonymous' && arg !== 'undefined' && arg !== 'none', 'CONFIG: reserved user/uplink name: ' + arg) assert(!arg.match(/\s/), 'CONFIG: invalid user name: ' + arg) assert(users[arg] == null, 'CONFIG: duplicate user/uplink name: ' + arg) users[arg] = true