Bump eslint-plugin-import to avoid vulnerability in dependency

This commit is contained in:
Henry Mercer 2023-01-18 20:26:59 +00:00
parent 10695e6a20
commit ed9506bbaf
1660 changed files with 67726 additions and 27926 deletions

View file

@ -3,9 +3,11 @@
var hasSymbols = require('has-symbols')();
var GetIntrinsic = require('get-intrinsic');
var callBound = require('call-bind/callBound');
var isString = require('is-string');
var $iterator = GetIntrinsic('%Symbol.iterator%', true);
var $stringSlice = callBound('String.prototype.slice');
var $String = GetIntrinsic('%String%', true);
module.exports = function getIteratorMethod(ES, iterable) {
var usingIterator;
@ -25,12 +27,12 @@ module.exports = function getIteratorMethod(ES, iterable) {
}
};
};
} else if (ES.Type(iterable) === 'String') {
} else if (isString(iterable)) {
usingIterator = function () {
var i = 0;
return {
next: function () {
var nextIndex = ES.AdvanceStringIndex(iterable, i, true);
var nextIndex = ES.AdvanceStringIndex($String(iterable), i, true);
var value = $stringSlice(iterable, i, nextIndex);
i = nextIndex;
return {