From f3bcb918bf60ef9f3e8fff0a98ca570bfca26888 Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Fri, 16 Aug 2019 12:00:50 +0200 Subject: [PATCH] luci-base: network.js: fix inverted logic in registerErrorCode() Signed-off-by: Jo-Philipp Wich --- modules/luci-base/htdocs/luci-static/resources/network.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/luci-base/htdocs/luci-static/resources/network.js b/modules/luci-base/htdocs/luci-static/resources/network.js index d6a97408a..fb23fba85 100644 --- a/modules/luci-base/htdocs/luci-static/resources/network.js +++ b/modules/luci-base/htdocs/luci-static/resources/network.js @@ -678,7 +678,7 @@ Network = L.Class.extend({ registerErrorCode: function(code, message) { if (typeof(code) == 'string' && typeof(message) == 'string' && - proto_errors.hasOwnProperty(code)) { + !proto_errors.hasOwnProperty(code)) { proto_errors[code] = message; return true; } -- 2.25.1