Skip to content

Commit 2ec7c9d

Browse files
Trottrichardlau
authored andcommitted
tools: remove exception for Node.js 8 and earlier
Remove exception in .eslintrc.js to accommodate versions of Node.js prior to 10.x. 10.x and later all support omitting catch block arguments. PR-URL: #38840 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Richard Lau <rlau@redhat.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Darshan Sen <raisinten@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
1 parent b4f60bb commit 2ec7c9d

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

.eslintrc.js

+1-4
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,7 @@ Module._findPath = (request, paths, isMain) => {
2525
if (!r && hacks.includes(request)) {
2626
try {
2727
return require.resolve(`./tools/node_modules/${request}`);
28-
// Keep the variable in place to ensure that ESLint started by older Node.js
29-
// versions work as expected.
30-
// eslint-disable-next-line no-unused-vars
31-
} catch (e) {
28+
} catch {
3229
return require.resolve(
3330
`./tools/node_modules/eslint/node_modules/${request}`);
3431
}

0 commit comments

Comments
 (0)