diff options
Diffstat (limited to 'node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js')
| -rw-r--r-- | node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js b/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js index c0f63bd5..33adc493 100644 --- a/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js +++ b/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js @@ -1,9 +1,9 @@ import arrayLikeToArray from "./arrayLikeToArray.js"; -export default function _unsupportedIterableToArray(o, minLen) { - if (!o) return; - if (typeof o === "string") return arrayLikeToArray(o, minLen); - var n = Object.prototype.toString.call(o).slice(8, -1); - if (n === "Object" && o.constructor) n = o.constructor.name; - if (n === "Map" || n === "Set") return Array.from(o); - if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen); -}
\ No newline at end of file +function _unsupportedIterableToArray(r, a) { + if (r) { + if ("string" == typeof r) return arrayLikeToArray(r, a); + var t = {}.toString.call(r).slice(8, -1); + return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? arrayLikeToArray(r, a) : void 0; + } +} +export { _unsupportedIterableToArray as default };
\ No newline at end of file |
