From 2f6ff1bb64ac4f3e201039c8e83f8eb95f73c769 Mon Sep 17 00:00:00 2001 From: silverwind Date: Sat, 9 Apr 2016 14:11:01 +0200 Subject: tools: update ESLint to 2.7.0 PR-URL: https://github.com/nodejs/node/pull/6132 Reviewed-By: Brian White Reviewed-By: Jeremiah Senkpiel Reviewed-By: Rich Trott Reviewed-By: thefourtheye --- tools/eslint/lib/rules/no-extra-boolean-cast.js | 2 ++ 1 file changed, 2 insertions(+) (limited to 'tools/eslint/lib/rules/no-extra-boolean-cast.js') diff --git a/tools/eslint/lib/rules/no-extra-boolean-cast.js b/tools/eslint/lib/rules/no-extra-boolean-cast.js index bd7495b891..c7ee1adc6b 100644 --- a/tools/eslint/lib/rules/no-extra-boolean-cast.js +++ b/tools/eslint/lib/rules/no-extra-boolean-cast.js @@ -31,6 +31,7 @@ module.exports = function(context) { return ( (BOOLEAN_NODE_TYPES.indexOf(parent.type) !== -1 && node === parent.test) || + // ! (parent.type === "UnaryExpression" && parent.operator === "!") @@ -52,6 +53,7 @@ module.exports = function(context) { } if (isInBooleanContext(parent, grandparent) || + // Boolean() and new Boolean() ((grandparent.type === "CallExpression" || grandparent.type === "NewExpression") && grandparent.callee.type === "Identifier" && -- cgit v1.2.1