From ecc50e9d912573eec108e143b561df219b46e183 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Mon, 19 Jun 2017 11:13:30 -0700 Subject: [PATCH] tools: fix error in custom ESLint rule Fix previously-unnoticed typo in `required-modules.js`. Backport-PR-URL: https://github.com/nodejs/node/pull/14360 Refs: https://github.com/nodejs/node/pull/13758#discussion_r122582786 PR-URL: https://github.com/nodejs/node/pull/13758 Reviewed-By: Teddy Katz Reviewed-By: Vse Mozhet Byt Reviewed-By: Colin Ihrig Reviewed-By: James M Snell Reviewed-By: Michael Dawson --- tools/eslint-rules/required-modules.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/eslint-rules/required-modules.js b/tools/eslint-rules/required-modules.js index 7691d5dd7d91a0..4a444809b7115c 100644 --- a/tools/eslint-rules/required-modules.js +++ b/tools/eslint-rules/required-modules.js @@ -75,7 +75,7 @@ module.exports = function(context) { if (foundModules.length < requiredModules.length) { var missingModules = requiredModules.filter( function(module) { - return foundModules.indexOf(module === -1); + return foundModules.indexOf(module) === -1; } ); missingModules.forEach(function(moduleName) {