Save current BZZZ config-ui state before CHORUS branding update
🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
50
install/config-ui/node_modules/es-iterator-helpers/aos/GetIteratorFlattenable.js
generated
vendored
Normal file
50
install/config-ui/node_modules/es-iterator-helpers/aos/GetIteratorFlattenable.js
generated
vendored
Normal file
@@ -0,0 +1,50 @@
|
||||
'use strict';
|
||||
|
||||
var $TypeError = require('es-errors/type');
|
||||
|
||||
var AdvanceStringIndex = require('es-abstract/2024/AdvanceStringIndex');
|
||||
var Call = require('es-abstract/2024/Call');
|
||||
var GetIteratorDirect = require('./GetIteratorDirect');
|
||||
var GetMethod = require('es-abstract/2024/GetMethod');
|
||||
var IsArray = require('es-abstract/2024/IsArray');
|
||||
var Type = require('es-abstract/2024/Type');
|
||||
|
||||
var getIteratorMethod = require('es-abstract/helpers/getIteratorMethod');
|
||||
|
||||
// https://tc39.es/proposal-iterator-helpers/#sec-getiteratorflattenable
|
||||
|
||||
module.exports = function GetIteratorFlattenable(obj, stringHandling) {
|
||||
if (stringHandling !== 'REJECT-STRINGS' && stringHandling !== 'ITERATE-STRINGS') {
|
||||
throw new $TypeError('Assertion failed: `stringHandling` must be "REJECT-STRINGS" or "ITERATE-STRINGS"');
|
||||
}
|
||||
|
||||
if (Type(obj) !== 'Object') {
|
||||
if (stringHandling === 'REJECT-STRINGS' || typeof obj !== 'string') {
|
||||
throw new $TypeError('obj must be an Object'); // step 1.a
|
||||
}
|
||||
}
|
||||
|
||||
var method = void undefined; // step 2
|
||||
|
||||
// method = GetMethod(obj, Symbol.iterator); // step 5.a
|
||||
method = getIteratorMethod(
|
||||
{
|
||||
AdvanceStringIndex: AdvanceStringIndex,
|
||||
GetMethod: GetMethod,
|
||||
IsArray: IsArray
|
||||
},
|
||||
obj
|
||||
);
|
||||
|
||||
var iterator;
|
||||
if (typeof method === 'undefined') { // step 3
|
||||
iterator = obj; // step 3.a
|
||||
} else { // step 4
|
||||
iterator = Call(method, obj); // step 4.a
|
||||
}
|
||||
|
||||
if (Type(iterator) !== 'Object') {
|
||||
throw new $TypeError('iterator must be an Object'); // step 5
|
||||
}
|
||||
return GetIteratorDirect(iterator); // step 6
|
||||
};
|
||||
Reference in New Issue
Block a user