Skip to content

Commit cd80550

Browse files
committed
avoid array destructuring syntax to support old Node.js versions
1 parent b4050cd commit cd80550

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/helpers/ruleTester.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,9 @@ if (semver.major(eslintPkg.version) >= 9) {
7777
this[PLUGINS] = {};
7878
}
7979

80-
const [pluginName, ruleName] = ruleId.split('/');
80+
const ruleIdSplit = ruleId.split('/');
81+
const pluginName = ruleIdSplit[0];
82+
const ruleName = ruleIdSplit[1];
8183

8284
if (!this[PLUGINS][pluginName]) {
8385
this[PLUGINS][pluginName] = { rules: {} };

0 commit comments

Comments
 (0)