From b9da9ffd72a34aa59fa6c98d36453a56980b917d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=94=AF=E7=84=B6?= Date: Mon, 29 Apr 2024 10:16:23 +0800 Subject: [PATCH] chore: fix linting errors --- lib/util/check-unsupported-builtins.js | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/lib/util/check-unsupported-builtins.js b/lib/util/check-unsupported-builtins.js index a5495e8b..5d4a742e 100644 --- a/lib/util/check-unsupported-builtins.js +++ b/lib/util/check-unsupported-builtins.js @@ -4,7 +4,7 @@ */ "use strict" -const { major, rsort } = require("semver") +const { rsort } = require("semver") const { ReferenceTracker } = require("@eslint-community/eslint-utils") const getConfiguredNodeVersion = require("./get-configured-node-version") const getSemverRange = require("./get-semver-range") @@ -39,12 +39,7 @@ function isSupported({ supported }, configured) { const [latest] = rsort(supported) const range = getSemverRange( - [ - ...supported.map( - version => `^${version}` - ), - `>= ${latest}`, - ].join("||") + [...supported.map(version => `^${version}`), `>= ${latest}`].join("||") ) if (range == null) {