@dereekb/zoho 11.1.8 → 12.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.cjs.js CHANGED
@@ -1,14 +1,30 @@
1
1
  'use strict';
2
2
 
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
3
  var util = require('@dereekb/util');
6
4
  var fetch = require('@dereekb/util/fetch');
7
5
  var makeError = require('make-error');
8
6
 
9
7
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
10
8
 
11
- var fails$c = function (exec) {
9
+ var check = function (it) {
10
+ return it && it.Math === Math && it;
11
+ };
12
+
13
+ // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
14
+ var global$j =
15
+ // eslint-disable-next-line es/no-global-this -- safe
16
+ check(typeof globalThis == 'object' && globalThis) ||
17
+ check(typeof window == 'object' && window) ||
18
+ // eslint-disable-next-line no-restricted-globals -- safe
19
+ check(typeof self == 'object' && self) ||
20
+ check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
21
+ check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
22
+ // eslint-disable-next-line no-new-func -- fallback
23
+ (function () { return this; })() || Function('return this')();
24
+
25
+ var objectGetOwnPropertyDescriptor = {};
26
+
27
+ var fails$h = function (exec) {
12
28
  try {
13
29
  return !!exec();
14
30
  } catch (error) {
@@ -16,17 +32,17 @@ var fails$c = function (exec) {
16
32
  }
17
33
  };
18
34
 
19
- var fails$b = fails$c;
35
+ var fails$g = fails$h;
20
36
 
21
37
  // Detect IE8's incomplete defineProperty implementation
22
- var descriptors = !fails$b(function () {
38
+ var descriptors = !fails$g(function () {
23
39
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
24
40
  return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
25
41
  });
26
42
 
27
- var fails$a = fails$c;
43
+ var fails$f = fails$h;
28
44
 
29
- var functionBindNative = !fails$a(function () {
45
+ var functionBindNative = !fails$f(function () {
30
46
  // eslint-disable-next-line es/no-function-prototype-bind -- safe
31
47
  var test = (function () { /* empty */ }).bind();
32
48
  // eslint-disable-next-line no-prototype-builtins -- safe
@@ -35,71 +51,97 @@ var functionBindNative = !fails$a(function () {
35
51
 
36
52
  var NATIVE_BIND$3 = functionBindNative;
37
53
 
38
- var FunctionPrototype$2 = Function.prototype;
39
- var call$d = FunctionPrototype$2.call;
40
- var uncurryThisWithBind = NATIVE_BIND$3 && FunctionPrototype$2.bind.bind(call$d, call$d);
54
+ var call$i = Function.prototype.call;
41
55
 
42
- var functionUncurryThis = NATIVE_BIND$3 ? uncurryThisWithBind : function (fn) {
43
- return function () {
44
- return call$d.apply(fn, arguments);
45
- };
56
+ var functionCall = NATIVE_BIND$3 ? call$i.bind(call$i) : function () {
57
+ return call$i.apply(call$i, arguments);
46
58
  };
47
59
 
48
- // we can't use just `it == null` since of `document.all` special case
49
- // https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
50
- var isNullOrUndefined$4 = function (it) {
51
- return it === null || it === undefined;
60
+ var objectPropertyIsEnumerable = {};
61
+
62
+ var $propertyIsEnumerable = {}.propertyIsEnumerable;
63
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
64
+ var getOwnPropertyDescriptor$3 = Object.getOwnPropertyDescriptor;
65
+
66
+ // Nashorn ~ JDK8 bug
67
+ var NASHORN_BUG = getOwnPropertyDescriptor$3 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
68
+
69
+ // `Object.prototype.propertyIsEnumerable` method implementation
70
+ // https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
71
+ objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
72
+ var descriptor = getOwnPropertyDescriptor$3(this, V);
73
+ return !!descriptor && descriptor.enumerable;
74
+ } : $propertyIsEnumerable;
75
+
76
+ var createPropertyDescriptor$4 = function (bitmap, value) {
77
+ return {
78
+ enumerable: !(bitmap & 1),
79
+ configurable: !(bitmap & 2),
80
+ writable: !(bitmap & 4),
81
+ value: value
82
+ };
52
83
  };
53
84
 
54
- var isNullOrUndefined$3 = isNullOrUndefined$4;
85
+ var NATIVE_BIND$2 = functionBindNative;
55
86
 
56
- var $TypeError$d = TypeError;
87
+ var FunctionPrototype$2 = Function.prototype;
88
+ var call$h = FunctionPrototype$2.call;
89
+ var uncurryThisWithBind = NATIVE_BIND$2 && FunctionPrototype$2.bind.bind(call$h, call$h);
57
90
 
58
- // `RequireObjectCoercible` abstract operation
59
- // https://tc39.es/ecma262/#sec-requireobjectcoercible
60
- var requireObjectCoercible$2 = function (it) {
61
- if (isNullOrUndefined$3(it)) throw new $TypeError$d("Can't call method on " + it);
62
- return it;
91
+ var functionUncurryThis = NATIVE_BIND$2 ? uncurryThisWithBind : function (fn) {
92
+ return function () {
93
+ return call$h.apply(fn, arguments);
94
+ };
63
95
  };
64
96
 
65
- var requireObjectCoercible$1 = requireObjectCoercible$2;
97
+ var uncurryThis$f = functionUncurryThis;
66
98
 
67
- var $Object$3 = Object;
99
+ var toString$3 = uncurryThis$f({}.toString);
100
+ var stringSlice$1 = uncurryThis$f(''.slice);
68
101
 
69
- // `ToObject` abstract operation
70
- // https://tc39.es/ecma262/#sec-toobject
71
- var toObject$3 = function (argument) {
72
- return $Object$3(requireObjectCoercible$1(argument));
102
+ var classofRaw$2 = function (it) {
103
+ return stringSlice$1(toString$3(it), 8, -1);
73
104
  };
74
105
 
75
106
  var uncurryThis$e = functionUncurryThis;
76
- var toObject$2 = toObject$3;
107
+ var fails$e = fails$h;
108
+ var classof$6 = classofRaw$2;
77
109
 
78
- var hasOwnProperty = uncurryThis$e({}.hasOwnProperty);
110
+ var $Object$4 = Object;
111
+ var split = uncurryThis$e(''.split);
79
112
 
80
- // `HasOwnProperty` abstract operation
81
- // https://tc39.es/ecma262/#sec-hasownproperty
82
- // eslint-disable-next-line es/no-object-hasown -- safe
83
- var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
84
- return hasOwnProperty(toObject$2(it), key);
113
+ // fallback for non-array-like ES3 and non-enumerable old V8 strings
114
+ var indexedObject = fails$e(function () {
115
+ // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
116
+ // eslint-disable-next-line no-prototype-builtins -- safe
117
+ return !$Object$4('z').propertyIsEnumerable(0);
118
+ }) ? function (it) {
119
+ return classof$6(it) === 'String' ? split(it, '') : $Object$4(it);
120
+ } : $Object$4;
121
+
122
+ // we can't use just `it == null` since of `document.all` special case
123
+ // https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
124
+ var isNullOrUndefined$4 = function (it) {
125
+ return it === null || it === undefined;
85
126
  };
86
127
 
87
- var DESCRIPTORS$a = descriptors;
88
- var hasOwn$9 = hasOwnProperty_1;
128
+ var isNullOrUndefined$3 = isNullOrUndefined$4;
89
129
 
90
- var FunctionPrototype$1 = Function.prototype;
91
- // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
92
- var getDescriptor = DESCRIPTORS$a && Object.getOwnPropertyDescriptor;
130
+ var $TypeError$f = TypeError;
93
131
 
94
- var EXISTS$1 = hasOwn$9(FunctionPrototype$1, 'name');
95
- // additional protection from minified / mangled / dropped function names
96
- var PROPER = EXISTS$1 && (function something() { /* empty */ }).name === 'something';
97
- var CONFIGURABLE$1 = EXISTS$1 && (!DESCRIPTORS$a || (DESCRIPTORS$a && getDescriptor(FunctionPrototype$1, 'name').configurable));
132
+ // `RequireObjectCoercible` abstract operation
133
+ // https://tc39.es/ecma262/#sec-requireobjectcoercible
134
+ var requireObjectCoercible$3 = function (it) {
135
+ if (isNullOrUndefined$3(it)) throw new $TypeError$f("Can't call method on " + it);
136
+ return it;
137
+ };
98
138
 
99
- var functionName = {
100
- EXISTS: EXISTS$1,
101
- PROPER: PROPER,
102
- CONFIGURABLE: CONFIGURABLE$1
139
+ // toObject with fallback for non-array-like ES3 strings
140
+ var IndexedObject$1 = indexedObject;
141
+ var requireObjectCoercible$2 = requireObjectCoercible$3;
142
+
143
+ var toIndexedObject$4 = function (it) {
144
+ return IndexedObject$1(requireObjectCoercible$2(it));
103
145
  };
104
146
 
105
147
  // https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
@@ -108,100 +150,27 @@ var documentAll = typeof document == 'object' && document.all;
108
150
  // `IsCallable` abstract operation
109
151
  // https://tc39.es/ecma262/#sec-iscallable
110
152
  // eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
111
- var isCallable$g = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
153
+ var isCallable$k = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
112
154
  return typeof argument == 'function' || argument === documentAll;
113
155
  } : function (argument) {
114
156
  return typeof argument == 'function';
115
157
  };
116
158
 
117
- var objectDefineProperty = {};
118
-
119
- var check = function (it) {
120
- return it && it.Math === Math && it;
121
- };
122
-
123
- // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
124
- var global$i =
125
- // eslint-disable-next-line es/no-global-this -- safe
126
- check(typeof globalThis == 'object' && globalThis) ||
127
- check(typeof window == 'object' && window) ||
128
- // eslint-disable-next-line no-restricted-globals -- safe
129
- check(typeof self == 'object' && self) ||
130
- check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
131
- check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
132
- // eslint-disable-next-line no-new-func -- fallback
133
- (function () { return this; })() || Function('return this')();
134
-
135
- var isCallable$f = isCallable$g;
136
-
137
- var isObject$9 = function (it) {
138
- return typeof it == 'object' ? it !== null : isCallable$f(it);
139
- };
140
-
141
- var global$h = global$i;
142
- var isObject$8 = isObject$9;
143
-
144
- var document$3 = global$h.document;
145
- // typeof document.createElement is 'object' in old IE
146
- var EXISTS = isObject$8(document$3) && isObject$8(document$3.createElement);
147
-
148
- var documentCreateElement$1 = function (it) {
149
- return EXISTS ? document$3.createElement(it) : {};
150
- };
151
-
152
- var DESCRIPTORS$9 = descriptors;
153
- var fails$9 = fails$c;
154
- var createElement$1 = documentCreateElement$1;
155
-
156
- // Thanks to IE8 for its funny defineProperty
157
- var ie8DomDefine = !DESCRIPTORS$9 && !fails$9(function () {
158
- // eslint-disable-next-line es/no-object-defineproperty -- required for testing
159
- return Object.defineProperty(createElement$1('div'), 'a', {
160
- get: function () { return 7; }
161
- }).a !== 7;
162
- });
163
-
164
- var DESCRIPTORS$8 = descriptors;
165
- var fails$8 = fails$c;
166
-
167
- // V8 ~ Chrome 36-
168
- // https://bugs.chromium.org/p/v8/issues/detail?id=3334
169
- var v8PrototypeDefineBug = DESCRIPTORS$8 && fails$8(function () {
170
- // eslint-disable-next-line es/no-object-defineproperty -- required for testing
171
- return Object.defineProperty(function () { /* empty */ }, 'prototype', {
172
- value: 42,
173
- writable: false
174
- }).prototype !== 42;
175
- });
176
-
177
- var isObject$7 = isObject$9;
178
-
179
- var $String$5 = String;
180
- var $TypeError$c = TypeError;
181
-
182
- // `Assert: Type(argument) is Object`
183
- var anObject$c = function (argument) {
184
- if (isObject$7(argument)) return argument;
185
- throw new $TypeError$c($String$5(argument) + ' is not an object');
186
- };
187
-
188
- var NATIVE_BIND$2 = functionBindNative;
189
-
190
- var call$c = Function.prototype.call;
159
+ var isCallable$j = isCallable$k;
191
160
 
192
- var functionCall = NATIVE_BIND$2 ? call$c.bind(call$c) : function () {
193
- return call$c.apply(call$c, arguments);
161
+ var isObject$d = function (it) {
162
+ return typeof it == 'object' ? it !== null : isCallable$j(it);
194
163
  };
195
164
 
196
- var global$g = global$i;
197
- var isCallable$e = isCallable$g;
165
+ var global$i = global$j;
166
+ var isCallable$i = isCallable$k;
198
167
 
199
168
  var aFunction = function (argument) {
200
- return isCallable$e(argument) ? argument : undefined;
169
+ return isCallable$i(argument) ? argument : undefined;
201
170
  };
202
171
 
203
- var getBuiltIn$7 = function (namespace, method) {
204
- return arguments.length < 2 ? aFunction(global$g[namespace]) : global$g[namespace] && global$g[namespace][method];
172
+ var getBuiltIn$8 = function (namespace, method) {
173
+ return arguments.length < 2 ? aFunction(global$i[namespace]) : global$i[namespace] && global$i[namespace][method];
205
174
  };
206
175
 
207
176
  var uncurryThis$d = functionUncurryThis;
@@ -210,11 +179,11 @@ var objectIsPrototypeOf = uncurryThis$d({}.isPrototypeOf);
210
179
 
211
180
  var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
212
181
 
213
- var global$f = global$i;
182
+ var global$h = global$j;
214
183
  var userAgent$3 = engineUserAgent;
215
184
 
216
- var process$3 = global$f.process;
217
- var Deno$1 = global$f.Deno;
185
+ var process$3 = global$h.process;
186
+ var Deno$1 = global$h.Deno;
218
187
  var versions = process$3 && process$3.versions || Deno$1 && Deno$1.version;
219
188
  var v8 = versions && versions.v8;
220
189
  var match, version;
@@ -240,19 +209,19 @@ var engineV8Version = version;
240
209
 
241
210
  /* eslint-disable es/no-symbol -- required for testing */
242
211
  var V8_VERSION$1 = engineV8Version;
243
- var fails$7 = fails$c;
244
- var global$e = global$i;
212
+ var fails$d = fails$h;
213
+ var global$g = global$j;
245
214
 
246
- var $String$4 = global$e.String;
215
+ var $String$5 = global$g.String;
247
216
 
248
217
  // eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
249
- var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$7(function () {
218
+ var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$d(function () {
250
219
  var symbol = Symbol('symbol detection');
251
220
  // Chrome 38 Symbol has incorrect toString conversion
252
221
  // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
253
222
  // nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,
254
223
  // of course, fail.
255
- return !$String$4(symbol) || !(Object(symbol) instanceof Symbol) ||
224
+ return !$String$5(symbol) || !(Object(symbol) instanceof Symbol) ||
256
225
  // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
257
226
  !Symbol.sham && V8_VERSION$1 && V8_VERSION$1 < 41;
258
227
  });
@@ -264,152 +233,178 @@ var useSymbolAsUid = NATIVE_SYMBOL$1
264
233
  && !Symbol.sham
265
234
  && typeof Symbol.iterator == 'symbol';
266
235
 
267
- var getBuiltIn$6 = getBuiltIn$7;
268
- var isCallable$d = isCallable$g;
269
- var isPrototypeOf$3 = objectIsPrototypeOf;
236
+ var getBuiltIn$7 = getBuiltIn$8;
237
+ var isCallable$h = isCallable$k;
238
+ var isPrototypeOf$4 = objectIsPrototypeOf;
270
239
  var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
271
240
 
272
- var $Object$2 = Object;
241
+ var $Object$3 = Object;
273
242
 
274
243
  var isSymbol$2 = USE_SYMBOL_AS_UID$1 ? function (it) {
275
244
  return typeof it == 'symbol';
276
245
  } : function (it) {
277
- var $Symbol = getBuiltIn$6('Symbol');
278
- return isCallable$d($Symbol) && isPrototypeOf$3($Symbol.prototype, $Object$2(it));
246
+ var $Symbol = getBuiltIn$7('Symbol');
247
+ return isCallable$h($Symbol) && isPrototypeOf$4($Symbol.prototype, $Object$3(it));
279
248
  };
280
249
 
281
- var $String$3 = String;
250
+ var $String$4 = String;
282
251
 
283
252
  var tryToString$4 = function (argument) {
284
253
  try {
285
- return $String$3(argument);
254
+ return $String$4(argument);
286
255
  } catch (error) {
287
256
  return 'Object';
288
257
  }
289
258
  };
290
259
 
291
- var isCallable$c = isCallable$g;
260
+ var isCallable$g = isCallable$k;
292
261
  var tryToString$3 = tryToString$4;
293
262
 
294
- var $TypeError$b = TypeError;
263
+ var $TypeError$e = TypeError;
295
264
 
296
265
  // `Assert: IsCallable(argument) is true`
297
- var aCallable$9 = function (argument) {
298
- if (isCallable$c(argument)) return argument;
299
- throw new $TypeError$b(tryToString$3(argument) + ' is not a function');
266
+ var aCallable$d = function (argument) {
267
+ if (isCallable$g(argument)) return argument;
268
+ throw new $TypeError$e(tryToString$3(argument) + ' is not a function');
300
269
  };
301
270
 
302
- var aCallable$8 = aCallable$9;
271
+ var aCallable$c = aCallable$d;
303
272
  var isNullOrUndefined$2 = isNullOrUndefined$4;
304
273
 
305
274
  // `GetMethod` abstract operation
306
275
  // https://tc39.es/ecma262/#sec-getmethod
307
- var getMethod$3 = function (V, P) {
276
+ var getMethod$4 = function (V, P) {
308
277
  var func = V[P];
309
- return isNullOrUndefined$2(func) ? undefined : aCallable$8(func);
278
+ return isNullOrUndefined$2(func) ? undefined : aCallable$c(func);
310
279
  };
311
280
 
312
- var call$b = functionCall;
313
- var isCallable$b = isCallable$g;
314
- var isObject$6 = isObject$9;
281
+ var call$g = functionCall;
282
+ var isCallable$f = isCallable$k;
283
+ var isObject$c = isObject$d;
315
284
 
316
- var $TypeError$a = TypeError;
285
+ var $TypeError$d = TypeError;
317
286
 
318
287
  // `OrdinaryToPrimitive` abstract operation
319
288
  // https://tc39.es/ecma262/#sec-ordinarytoprimitive
320
289
  var ordinaryToPrimitive$1 = function (input, pref) {
321
290
  var fn, val;
322
- if (pref === 'string' && isCallable$b(fn = input.toString) && !isObject$6(val = call$b(fn, input))) return val;
323
- if (isCallable$b(fn = input.valueOf) && !isObject$6(val = call$b(fn, input))) return val;
324
- if (pref !== 'string' && isCallable$b(fn = input.toString) && !isObject$6(val = call$b(fn, input))) return val;
325
- throw new $TypeError$a("Can't convert object to primitive value");
291
+ if (pref === 'string' && isCallable$f(fn = input.toString) && !isObject$c(val = call$g(fn, input))) return val;
292
+ if (isCallable$f(fn = input.valueOf) && !isObject$c(val = call$g(fn, input))) return val;
293
+ if (pref !== 'string' && isCallable$f(fn = input.toString) && !isObject$c(val = call$g(fn, input))) return val;
294
+ throw new $TypeError$d("Can't convert object to primitive value");
326
295
  };
327
296
 
328
- var shared$3 = {exports: {}};
297
+ var sharedStore = {exports: {}};
298
+
299
+ var isPure = false;
329
300
 
330
- var global$d = global$i;
301
+ var global$f = global$j;
331
302
 
332
303
  // eslint-disable-next-line es/no-object-defineproperty -- safe
333
- var defineProperty$5 = Object.defineProperty;
304
+ var defineProperty$6 = Object.defineProperty;
334
305
 
335
306
  var defineGlobalProperty$3 = function (key, value) {
336
307
  try {
337
- defineProperty$5(global$d, key, { value: value, configurable: true, writable: true });
308
+ defineProperty$6(global$f, key, { value: value, configurable: true, writable: true });
338
309
  } catch (error) {
339
- global$d[key] = value;
310
+ global$f[key] = value;
340
311
  } return value;
341
312
  };
342
313
 
343
- var global$c = global$i;
314
+ var globalThis$1 = global$j;
344
315
  var defineGlobalProperty$2 = defineGlobalProperty$3;
345
316
 
346
317
  var SHARED = '__core-js_shared__';
347
- var store$3 = global$c[SHARED] || defineGlobalProperty$2(SHARED, {});
348
-
349
- var sharedStore = store$3;
318
+ var store$3 = sharedStore.exports = globalThis$1[SHARED] || defineGlobalProperty$2(SHARED, {});
350
319
 
351
- var store$2 = sharedStore;
352
-
353
- (shared$3.exports = function (key, value) {
354
- return store$2[key] || (store$2[key] = value !== undefined ? value : {});
355
- })('versions', []).push({
356
- version: '3.35.1',
320
+ (store$3.versions || (store$3.versions = [])).push({
321
+ version: '3.36.1',
357
322
  mode: 'global',
358
323
  copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
359
- license: 'https://github.com/zloirock/core-js/blob/v3.35.1/LICENSE',
324
+ license: 'https://github.com/zloirock/core-js/blob/v3.36.1/LICENSE',
360
325
  source: 'https://github.com/zloirock/core-js'
361
326
  });
362
327
 
328
+ var sharedStoreExports = sharedStore.exports;
329
+
330
+ var store$2 = sharedStoreExports;
331
+
332
+ var shared$3 = function (key, value) {
333
+ return store$2[key] || (store$2[key] = value || {});
334
+ };
335
+
336
+ var requireObjectCoercible$1 = requireObjectCoercible$3;
337
+
338
+ var $Object$2 = Object;
339
+
340
+ // `ToObject` abstract operation
341
+ // https://tc39.es/ecma262/#sec-toobject
342
+ var toObject$5 = function (argument) {
343
+ return $Object$2(requireObjectCoercible$1(argument));
344
+ };
345
+
363
346
  var uncurryThis$c = functionUncurryThis;
347
+ var toObject$4 = toObject$5;
348
+
349
+ var hasOwnProperty = uncurryThis$c({}.hasOwnProperty);
350
+
351
+ // `HasOwnProperty` abstract operation
352
+ // https://tc39.es/ecma262/#sec-hasownproperty
353
+ // eslint-disable-next-line es/no-object-hasown -- safe
354
+ var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
355
+ return hasOwnProperty(toObject$4(it), key);
356
+ };
357
+
358
+ var uncurryThis$b = functionUncurryThis;
364
359
 
365
360
  var id = 0;
366
361
  var postfix = Math.random();
367
- var toString$2 = uncurryThis$c(1.0.toString);
362
+ var toString$2 = uncurryThis$b(1.0.toString);
368
363
 
369
364
  var uid$2 = function (key) {
370
365
  return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$2(++id + postfix, 36);
371
366
  };
372
367
 
373
- var global$b = global$i;
374
- var shared$2 = shared$3.exports;
375
- var hasOwn$8 = hasOwnProperty_1;
368
+ var global$e = global$j;
369
+ var shared$2 = shared$3;
370
+ var hasOwn$c = hasOwnProperty_1;
376
371
  var uid$1 = uid$2;
377
372
  var NATIVE_SYMBOL = symbolConstructorDetection;
378
373
  var USE_SYMBOL_AS_UID = useSymbolAsUid;
379
374
 
380
- var Symbol$1 = global$b.Symbol;
375
+ var Symbol$1 = global$e.Symbol;
381
376
  var WellKnownSymbolsStore = shared$2('wks');
382
377
  var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$1['for'] || Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
383
378
 
384
- var wellKnownSymbol$c = function (name) {
385
- if (!hasOwn$8(WellKnownSymbolsStore, name)) {
386
- WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn$8(Symbol$1, name)
379
+ var wellKnownSymbol$f = function (name) {
380
+ if (!hasOwn$c(WellKnownSymbolsStore, name)) {
381
+ WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn$c(Symbol$1, name)
387
382
  ? Symbol$1[name]
388
383
  : createWellKnownSymbol('Symbol.' + name);
389
384
  } return WellKnownSymbolsStore[name];
390
385
  };
391
386
 
392
- var call$a = functionCall;
393
- var isObject$5 = isObject$9;
387
+ var call$f = functionCall;
388
+ var isObject$b = isObject$d;
394
389
  var isSymbol$1 = isSymbol$2;
395
- var getMethod$2 = getMethod$3;
390
+ var getMethod$3 = getMethod$4;
396
391
  var ordinaryToPrimitive = ordinaryToPrimitive$1;
397
- var wellKnownSymbol$b = wellKnownSymbol$c;
392
+ var wellKnownSymbol$e = wellKnownSymbol$f;
398
393
 
399
- var $TypeError$9 = TypeError;
400
- var TO_PRIMITIVE = wellKnownSymbol$b('toPrimitive');
394
+ var $TypeError$c = TypeError;
395
+ var TO_PRIMITIVE = wellKnownSymbol$e('toPrimitive');
401
396
 
402
397
  // `ToPrimitive` abstract operation
403
398
  // https://tc39.es/ecma262/#sec-toprimitive
404
399
  var toPrimitive$1 = function (input, pref) {
405
- if (!isObject$5(input) || isSymbol$1(input)) return input;
406
- var exoticToPrim = getMethod$2(input, TO_PRIMITIVE);
400
+ if (!isObject$b(input) || isSymbol$1(input)) return input;
401
+ var exoticToPrim = getMethod$3(input, TO_PRIMITIVE);
407
402
  var result;
408
403
  if (exoticToPrim) {
409
404
  if (pref === undefined) pref = 'default';
410
- result = call$a(exoticToPrim, input, pref);
411
- if (!isObject$5(result) || isSymbol$1(result)) return result;
412
- throw new $TypeError$9("Can't convert object to primitive value");
405
+ result = call$f(exoticToPrim, input, pref);
406
+ if (!isObject$b(result) || isSymbol$1(result)) return result;
407
+ throw new $TypeError$c("Can't convert object to primitive value");
413
408
  }
414
409
  if (pref === undefined) pref = 'number';
415
410
  return ordinaryToPrimitive(input, pref);
@@ -425,117 +420,198 @@ var toPropertyKey$2 = function (argument) {
425
420
  return isSymbol(key) ? key : key + '';
426
421
  };
427
422
 
428
- var DESCRIPTORS$7 = descriptors;
423
+ var global$d = global$j;
424
+ var isObject$a = isObject$d;
425
+
426
+ var document$3 = global$d.document;
427
+ // typeof document.createElement is 'object' in old IE
428
+ var EXISTS$1 = isObject$a(document$3) && isObject$a(document$3.createElement);
429
+
430
+ var documentCreateElement$1 = function (it) {
431
+ return EXISTS$1 ? document$3.createElement(it) : {};
432
+ };
433
+
434
+ var DESCRIPTORS$e = descriptors;
435
+ var fails$c = fails$h;
436
+ var createElement$1 = documentCreateElement$1;
437
+
438
+ // Thanks to IE8 for its funny defineProperty
439
+ var ie8DomDefine = !DESCRIPTORS$e && !fails$c(function () {
440
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
441
+ return Object.defineProperty(createElement$1('div'), 'a', {
442
+ get: function () { return 7; }
443
+ }).a !== 7;
444
+ });
445
+
446
+ var DESCRIPTORS$d = descriptors;
447
+ var call$e = functionCall;
448
+ var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
449
+ var createPropertyDescriptor$3 = createPropertyDescriptor$4;
450
+ var toIndexedObject$3 = toIndexedObject$4;
451
+ var toPropertyKey$1 = toPropertyKey$2;
452
+ var hasOwn$b = hasOwnProperty_1;
429
453
  var IE8_DOM_DEFINE$1 = ie8DomDefine;
454
+
455
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
456
+ var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
457
+
458
+ // `Object.getOwnPropertyDescriptor` method
459
+ // https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
460
+ objectGetOwnPropertyDescriptor.f = DESCRIPTORS$d ? $getOwnPropertyDescriptor$1 : function getOwnPropertyDescriptor(O, P) {
461
+ O = toIndexedObject$3(O);
462
+ P = toPropertyKey$1(P);
463
+ if (IE8_DOM_DEFINE$1) try {
464
+ return $getOwnPropertyDescriptor$1(O, P);
465
+ } catch (error) { /* empty */ }
466
+ if (hasOwn$b(O, P)) return createPropertyDescriptor$3(!call$e(propertyIsEnumerableModule$1.f, O, P), O[P]);
467
+ };
468
+
469
+ var objectDefineProperty = {};
470
+
471
+ var DESCRIPTORS$c = descriptors;
472
+ var fails$b = fails$h;
473
+
474
+ // V8 ~ Chrome 36-
475
+ // https://bugs.chromium.org/p/v8/issues/detail?id=3334
476
+ var v8PrototypeDefineBug = DESCRIPTORS$c && fails$b(function () {
477
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
478
+ return Object.defineProperty(function () { /* empty */ }, 'prototype', {
479
+ value: 42,
480
+ writable: false
481
+ }).prototype !== 42;
482
+ });
483
+
484
+ var isObject$9 = isObject$d;
485
+
486
+ var $String$3 = String;
487
+ var $TypeError$b = TypeError;
488
+
489
+ // `Assert: Type(argument) is Object`
490
+ var anObject$i = function (argument) {
491
+ if (isObject$9(argument)) return argument;
492
+ throw new $TypeError$b($String$3(argument) + ' is not an object');
493
+ };
494
+
495
+ var DESCRIPTORS$b = descriptors;
496
+ var IE8_DOM_DEFINE = ie8DomDefine;
430
497
  var V8_PROTOTYPE_DEFINE_BUG$1 = v8PrototypeDefineBug;
431
- var anObject$b = anObject$c;
432
- var toPropertyKey$1 = toPropertyKey$2;
498
+ var anObject$h = anObject$i;
499
+ var toPropertyKey = toPropertyKey$2;
433
500
 
434
- var $TypeError$8 = TypeError;
501
+ var $TypeError$a = TypeError;
435
502
  // eslint-disable-next-line es/no-object-defineproperty -- safe
436
503
  var $defineProperty = Object.defineProperty;
437
504
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
438
- var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
505
+ var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
439
506
  var ENUMERABLE = 'enumerable';
440
- var CONFIGURABLE = 'configurable';
507
+ var CONFIGURABLE$1 = 'configurable';
441
508
  var WRITABLE = 'writable';
442
509
 
443
510
  // `Object.defineProperty` method
444
511
  // https://tc39.es/ecma262/#sec-object.defineproperty
445
- objectDefineProperty.f = DESCRIPTORS$7 ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) {
446
- anObject$b(O);
447
- P = toPropertyKey$1(P);
448
- anObject$b(Attributes);
512
+ objectDefineProperty.f = DESCRIPTORS$b ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) {
513
+ anObject$h(O);
514
+ P = toPropertyKey(P);
515
+ anObject$h(Attributes);
449
516
  if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
450
- var current = $getOwnPropertyDescriptor$1(O, P);
517
+ var current = $getOwnPropertyDescriptor(O, P);
451
518
  if (current && current[WRITABLE]) {
452
519
  O[P] = Attributes.value;
453
520
  Attributes = {
454
- configurable: CONFIGURABLE in Attributes ? Attributes[CONFIGURABLE] : current[CONFIGURABLE],
521
+ configurable: CONFIGURABLE$1 in Attributes ? Attributes[CONFIGURABLE$1] : current[CONFIGURABLE$1],
455
522
  enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],
456
523
  writable: false
457
524
  };
458
525
  }
459
526
  } return $defineProperty(O, P, Attributes);
460
527
  } : $defineProperty : function defineProperty(O, P, Attributes) {
461
- anObject$b(O);
462
- P = toPropertyKey$1(P);
463
- anObject$b(Attributes);
464
- if (IE8_DOM_DEFINE$1) try {
528
+ anObject$h(O);
529
+ P = toPropertyKey(P);
530
+ anObject$h(Attributes);
531
+ if (IE8_DOM_DEFINE) try {
465
532
  return $defineProperty(O, P, Attributes);
466
533
  } catch (error) { /* empty */ }
467
- if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$8('Accessors not supported');
534
+ if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$a('Accessors not supported');
468
535
  if ('value' in Attributes) O[P] = Attributes.value;
469
536
  return O;
470
537
  };
471
538
 
472
- var makeBuiltIn$3 = {exports: {}};
473
-
474
- var uncurryThis$b = functionUncurryThis;
475
- var isCallable$a = isCallable$g;
476
- var store$1 = sharedStore;
539
+ var DESCRIPTORS$a = descriptors;
540
+ var definePropertyModule$4 = objectDefineProperty;
541
+ var createPropertyDescriptor$2 = createPropertyDescriptor$4;
477
542
 
478
- var functionToString = uncurryThis$b(Function.toString);
543
+ var createNonEnumerableProperty$6 = DESCRIPTORS$a ? function (object, key, value) {
544
+ return definePropertyModule$4.f(object, key, createPropertyDescriptor$2(1, value));
545
+ } : function (object, key, value) {
546
+ object[key] = value;
547
+ return object;
548
+ };
479
549
 
480
- // this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
481
- if (!isCallable$a(store$1.inspectSource)) {
482
- store$1.inspectSource = function (it) {
483
- return functionToString(it);
484
- };
485
- }
550
+ var makeBuiltIn$3 = {exports: {}};
486
551
 
487
- var inspectSource$3 = store$1.inspectSource;
552
+ var DESCRIPTORS$9 = descriptors;
553
+ var hasOwn$a = hasOwnProperty_1;
488
554
 
489
- var global$a = global$i;
490
- var isCallable$9 = isCallable$g;
555
+ var FunctionPrototype$1 = Function.prototype;
556
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
557
+ var getDescriptor = DESCRIPTORS$9 && Object.getOwnPropertyDescriptor;
491
558
 
492
- var WeakMap$1 = global$a.WeakMap;
559
+ var EXISTS = hasOwn$a(FunctionPrototype$1, 'name');
560
+ // additional protection from minified / mangled / dropped function names
561
+ var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
562
+ var CONFIGURABLE = EXISTS && (!DESCRIPTORS$9 || (DESCRIPTORS$9 && getDescriptor(FunctionPrototype$1, 'name').configurable));
493
563
 
494
- var weakMapBasicDetection = isCallable$9(WeakMap$1) && /native code/.test(String(WeakMap$1));
564
+ var functionName = {
565
+ EXISTS: EXISTS,
566
+ PROPER: PROPER,
567
+ CONFIGURABLE: CONFIGURABLE
568
+ };
495
569
 
496
- var createPropertyDescriptor$2 = function (bitmap, value) {
497
- return {
498
- enumerable: !(bitmap & 1),
499
- configurable: !(bitmap & 2),
500
- writable: !(bitmap & 4),
501
- value: value
570
+ var uncurryThis$a = functionUncurryThis;
571
+ var isCallable$e = isCallable$k;
572
+ var store$1 = sharedStoreExports;
573
+
574
+ var functionToString = uncurryThis$a(Function.toString);
575
+
576
+ // this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
577
+ if (!isCallable$e(store$1.inspectSource)) {
578
+ store$1.inspectSource = function (it) {
579
+ return functionToString(it);
502
580
  };
503
- };
581
+ }
504
582
 
505
- var DESCRIPTORS$6 = descriptors;
506
- var definePropertyModule$3 = objectDefineProperty;
507
- var createPropertyDescriptor$1 = createPropertyDescriptor$2;
583
+ var inspectSource$3 = store$1.inspectSource;
508
584
 
509
- var createNonEnumerableProperty$2 = DESCRIPTORS$6 ? function (object, key, value) {
510
- return definePropertyModule$3.f(object, key, createPropertyDescriptor$1(1, value));
511
- } : function (object, key, value) {
512
- object[key] = value;
513
- return object;
514
- };
585
+ var global$c = global$j;
586
+ var isCallable$d = isCallable$k;
587
+
588
+ var WeakMap$1 = global$c.WeakMap;
589
+
590
+ var weakMapBasicDetection = isCallable$d(WeakMap$1) && /native code/.test(String(WeakMap$1));
515
591
 
516
- var shared$1 = shared$3.exports;
592
+ var shared$1 = shared$3;
517
593
  var uid = uid$2;
518
594
 
519
595
  var keys = shared$1('keys');
520
596
 
521
- var sharedKey$2 = function (key) {
597
+ var sharedKey$3 = function (key) {
522
598
  return keys[key] || (keys[key] = uid(key));
523
599
  };
524
600
 
525
601
  var hiddenKeys$4 = {};
526
602
 
527
603
  var NATIVE_WEAK_MAP = weakMapBasicDetection;
528
- var global$9 = global$i;
529
- var isObject$4 = isObject$9;
530
- var createNonEnumerableProperty$1 = createNonEnumerableProperty$2;
531
- var hasOwn$7 = hasOwnProperty_1;
532
- var shared = sharedStore;
533
- var sharedKey$1 = sharedKey$2;
604
+ var global$b = global$j;
605
+ var isObject$8 = isObject$d;
606
+ var createNonEnumerableProperty$5 = createNonEnumerableProperty$6;
607
+ var hasOwn$9 = hasOwnProperty_1;
608
+ var shared = sharedStoreExports;
609
+ var sharedKey$2 = sharedKey$3;
534
610
  var hiddenKeys$3 = hiddenKeys$4;
535
611
 
536
612
  var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
537
- var TypeError$2 = global$9.TypeError;
538
- var WeakMap = global$9.WeakMap;
613
+ var TypeError$2 = global$b.TypeError;
614
+ var WeakMap = global$b.WeakMap;
539
615
  var set$1, get, has;
540
616
 
541
617
  var enforce = function (it) {
@@ -545,7 +621,7 @@ var enforce = function (it) {
545
621
  var getterFor = function (TYPE) {
546
622
  return function (it) {
547
623
  var state;
548
- if (!isObject$4(it) || (state = get(it)).type !== TYPE) {
624
+ if (!isObject$8(it) || (state = get(it)).type !== TYPE) {
549
625
  throw new TypeError$2('Incompatible receiver, ' + TYPE + ' required');
550
626
  } return state;
551
627
  };
@@ -571,19 +647,19 @@ if (NATIVE_WEAK_MAP || shared.state) {
571
647
  return store.has(it);
572
648
  };
573
649
  } else {
574
- var STATE = sharedKey$1('state');
650
+ var STATE = sharedKey$2('state');
575
651
  hiddenKeys$3[STATE] = true;
576
652
  set$1 = function (it, metadata) {
577
- if (hasOwn$7(it, STATE)) throw new TypeError$2(OBJECT_ALREADY_INITIALIZED);
653
+ if (hasOwn$9(it, STATE)) throw new TypeError$2(OBJECT_ALREADY_INITIALIZED);
578
654
  metadata.facade = it;
579
- createNonEnumerableProperty$1(it, STATE, metadata);
655
+ createNonEnumerableProperty$5(it, STATE, metadata);
580
656
  return metadata;
581
657
  };
582
658
  get = function (it) {
583
- return hasOwn$7(it, STATE) ? it[STATE] : {};
659
+ return hasOwn$9(it, STATE) ? it[STATE] : {};
584
660
  };
585
661
  has = function (it) {
586
- return hasOwn$7(it, STATE);
662
+ return hasOwn$9(it, STATE);
587
663
  };
588
664
  }
589
665
 
@@ -595,51 +671,51 @@ var internalState = {
595
671
  getterFor: getterFor
596
672
  };
597
673
 
598
- var uncurryThis$a = functionUncurryThis;
599
- var fails$6 = fails$c;
600
- var isCallable$8 = isCallable$g;
601
- var hasOwn$6 = hasOwnProperty_1;
602
- var DESCRIPTORS$5 = descriptors;
674
+ var uncurryThis$9 = functionUncurryThis;
675
+ var fails$a = fails$h;
676
+ var isCallable$c = isCallable$k;
677
+ var hasOwn$8 = hasOwnProperty_1;
678
+ var DESCRIPTORS$8 = descriptors;
603
679
  var CONFIGURABLE_FUNCTION_NAME = functionName.CONFIGURABLE;
604
680
  var inspectSource$2 = inspectSource$3;
605
- var InternalStateModule$1 = internalState;
681
+ var InternalStateModule$2 = internalState;
606
682
 
607
- var enforceInternalState = InternalStateModule$1.enforce;
608
- var getInternalState = InternalStateModule$1.get;
683
+ var enforceInternalState = InternalStateModule$2.enforce;
684
+ var getInternalState = InternalStateModule$2.get;
609
685
  var $String$2 = String;
610
686
  // eslint-disable-next-line es/no-object-defineproperty -- safe
611
- var defineProperty$4 = Object.defineProperty;
612
- var stringSlice$1 = uncurryThis$a(''.slice);
613
- var replace = uncurryThis$a(''.replace);
614
- var join = uncurryThis$a([].join);
687
+ var defineProperty$5 = Object.defineProperty;
688
+ var stringSlice = uncurryThis$9(''.slice);
689
+ var replace$1 = uncurryThis$9(''.replace);
690
+ var join = uncurryThis$9([].join);
615
691
 
616
- var CONFIGURABLE_LENGTH = DESCRIPTORS$5 && !fails$6(function () {
617
- return defineProperty$4(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
692
+ var CONFIGURABLE_LENGTH = DESCRIPTORS$8 && !fails$a(function () {
693
+ return defineProperty$5(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
618
694
  });
619
695
 
620
696
  var TEMPLATE = String(String).split('String');
621
697
 
622
698
  var makeBuiltIn$2 = makeBuiltIn$3.exports = function (value, name, options) {
623
- if (stringSlice$1($String$2(name), 0, 7) === 'Symbol(') {
624
- name = '[' + replace($String$2(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
699
+ if (stringSlice($String$2(name), 0, 7) === 'Symbol(') {
700
+ name = '[' + replace$1($String$2(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
625
701
  }
626
702
  if (options && options.getter) name = 'get ' + name;
627
703
  if (options && options.setter) name = 'set ' + name;
628
- if (!hasOwn$6(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {
629
- if (DESCRIPTORS$5) defineProperty$4(value, 'name', { value: name, configurable: true });
704
+ if (!hasOwn$8(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {
705
+ if (DESCRIPTORS$8) defineProperty$5(value, 'name', { value: name, configurable: true });
630
706
  else value.name = name;
631
707
  }
632
- if (CONFIGURABLE_LENGTH && options && hasOwn$6(options, 'arity') && value.length !== options.arity) {
633
- defineProperty$4(value, 'length', { value: options.arity });
708
+ if (CONFIGURABLE_LENGTH && options && hasOwn$8(options, 'arity') && value.length !== options.arity) {
709
+ defineProperty$5(value, 'length', { value: options.arity });
634
710
  }
635
711
  try {
636
- if (options && hasOwn$6(options, 'constructor') && options.constructor) {
637
- if (DESCRIPTORS$5) defineProperty$4(value, 'prototype', { writable: false });
712
+ if (options && hasOwn$8(options, 'constructor') && options.constructor) {
713
+ if (DESCRIPTORS$8) defineProperty$5(value, 'prototype', { writable: false });
638
714
  // in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
639
715
  } else if (value.prototype) value.prototype = undefined;
640
716
  } catch (error) { /* empty */ }
641
717
  var state = enforceInternalState(value);
642
- if (!hasOwn$6(state, 'source')) {
718
+ if (!hasOwn$8(state, 'source')) {
643
719
  state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
644
720
  } return value;
645
721
  };
@@ -647,19 +723,21 @@ var makeBuiltIn$2 = makeBuiltIn$3.exports = function (value, name, options) {
647
723
  // add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
648
724
  // eslint-disable-next-line no-extend-native -- required
649
725
  Function.prototype.toString = makeBuiltIn$2(function toString() {
650
- return isCallable$8(this) && getInternalState(this).source || inspectSource$2(this);
726
+ return isCallable$c(this) && getInternalState(this).source || inspectSource$2(this);
651
727
  }, 'toString');
652
728
 
653
- var isCallable$7 = isCallable$g;
654
- var definePropertyModule$2 = objectDefineProperty;
655
- var makeBuiltIn$1 = makeBuiltIn$3.exports;
729
+ var makeBuiltInExports = makeBuiltIn$3.exports;
730
+
731
+ var isCallable$b = isCallable$k;
732
+ var definePropertyModule$3 = objectDefineProperty;
733
+ var makeBuiltIn$1 = makeBuiltInExports;
656
734
  var defineGlobalProperty$1 = defineGlobalProperty$3;
657
735
 
658
- var defineBuiltIn$4 = function (O, key, value, options) {
736
+ var defineBuiltIn$6 = function (O, key, value, options) {
659
737
  if (!options) options = {};
660
738
  var simple = options.enumerable;
661
739
  var name = options.name !== undefined ? options.name : key;
662
- if (isCallable$7(value)) makeBuiltIn$1(value, name, options);
740
+ if (isCallable$b(value)) makeBuiltIn$1(value, name, options);
663
741
  if (options.global) {
664
742
  if (simple) O[key] = value;
665
743
  else defineGlobalProperty$1(key, value);
@@ -669,7 +747,7 @@ var defineBuiltIn$4 = function (O, key, value, options) {
669
747
  else if (O[key]) simple = true;
670
748
  } catch (error) { /* empty */ }
671
749
  if (simple) O[key] = value;
672
- else definePropertyModule$2.f(O, key, {
750
+ else definePropertyModule$3.f(O, key, {
673
751
  value: value,
674
752
  enumerable: false,
675
753
  configurable: !options.nonConfigurable,
@@ -678,185 +756,6 @@ var defineBuiltIn$4 = function (O, key, value, options) {
678
756
  } return O;
679
757
  };
680
758
 
681
- var wellKnownSymbol$a = wellKnownSymbol$c;
682
-
683
- var TO_STRING_TAG$2 = wellKnownSymbol$a('toStringTag');
684
- var test = {};
685
-
686
- test[TO_STRING_TAG$2] = 'z';
687
-
688
- var toStringTagSupport = String(test) === '[object z]';
689
-
690
- var uncurryThis$9 = functionUncurryThis;
691
-
692
- var toString$1 = uncurryThis$9({}.toString);
693
- var stringSlice = uncurryThis$9(''.slice);
694
-
695
- var classofRaw$2 = function (it) {
696
- return stringSlice(toString$1(it), 8, -1);
697
- };
698
-
699
- var TO_STRING_TAG_SUPPORT = toStringTagSupport;
700
- var isCallable$6 = isCallable$g;
701
- var classofRaw$1 = classofRaw$2;
702
- var wellKnownSymbol$9 = wellKnownSymbol$c;
703
-
704
- var TO_STRING_TAG$1 = wellKnownSymbol$9('toStringTag');
705
- var $Object$1 = Object;
706
-
707
- // ES3 wrong here
708
- var CORRECT_ARGUMENTS = classofRaw$1(function () { return arguments; }()) === 'Arguments';
709
-
710
- // fallback for IE11 Script Access Denied error
711
- var tryGet = function (it, key) {
712
- try {
713
- return it[key];
714
- } catch (error) { /* empty */ }
715
- };
716
-
717
- // getting tag from ES6+ `Object.prototype.toString`
718
- var classof$6 = TO_STRING_TAG_SUPPORT ? classofRaw$1 : function (it) {
719
- var O, tag, result;
720
- return it === undefined ? 'Undefined' : it === null ? 'Null'
721
- // @@toStringTag case
722
- : typeof (tag = tryGet(O = $Object$1(it), TO_STRING_TAG$1)) == 'string' ? tag
723
- // builtinTag case
724
- : CORRECT_ARGUMENTS ? classofRaw$1(O)
725
- // ES3 arguments fallback
726
- : (result = classofRaw$1(O)) === 'Object' && isCallable$6(O.callee) ? 'Arguments' : result;
727
- };
728
-
729
- var classof$5 = classof$6;
730
-
731
- var $String$1 = String;
732
-
733
- var toString = function (argument) {
734
- if (classof$5(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
735
- return $String$1(argument);
736
- };
737
-
738
- var anObject$a = anObject$c;
739
-
740
- // `RegExp.prototype.flags` getter implementation
741
- // https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
742
- var regexpFlags = function () {
743
- var that = anObject$a(this);
744
- var result = '';
745
- if (that.hasIndices) result += 'd';
746
- if (that.global) result += 'g';
747
- if (that.ignoreCase) result += 'i';
748
- if (that.multiline) result += 'm';
749
- if (that.dotAll) result += 's';
750
- if (that.unicode) result += 'u';
751
- if (that.unicodeSets) result += 'v';
752
- if (that.sticky) result += 'y';
753
- return result;
754
- };
755
-
756
- var call$9 = functionCall;
757
- var hasOwn$5 = hasOwnProperty_1;
758
- var isPrototypeOf$2 = objectIsPrototypeOf;
759
- var regExpFlags = regexpFlags;
760
-
761
- var RegExpPrototype$1 = RegExp.prototype;
762
-
763
- var regexpGetFlags = function (R) {
764
- var flags = R.flags;
765
- return flags === undefined && !('flags' in RegExpPrototype$1) && !hasOwn$5(R, 'flags') && isPrototypeOf$2(RegExpPrototype$1, R)
766
- ? call$9(regExpFlags, R) : flags;
767
- };
768
-
769
- var PROPER_FUNCTION_NAME = functionName.PROPER;
770
- var defineBuiltIn$3 = defineBuiltIn$4;
771
- var anObject$9 = anObject$c;
772
- var $toString = toString;
773
- var fails$5 = fails$c;
774
- var getRegExpFlags = regexpGetFlags;
775
-
776
- var TO_STRING = 'toString';
777
- var RegExpPrototype = RegExp.prototype;
778
- var nativeToString = RegExpPrototype[TO_STRING];
779
-
780
- var NOT_GENERIC = fails$5(function () { return nativeToString.call({ source: 'a', flags: 'b' }) !== '/a/b'; });
781
- // FF44- RegExp#toString has a wrong name
782
- var INCORRECT_NAME = PROPER_FUNCTION_NAME && nativeToString.name !== TO_STRING;
783
-
784
- // `RegExp.prototype.toString` method
785
- // https://tc39.es/ecma262/#sec-regexp.prototype.tostring
786
- if (NOT_GENERIC || INCORRECT_NAME) {
787
- defineBuiltIn$3(RegExpPrototype, TO_STRING, function toString() {
788
- var R = anObject$9(this);
789
- var pattern = $toString(R.source);
790
- var flags = $toString(getRegExpFlags(R));
791
- return '/' + pattern + '/' + flags;
792
- }, { unsafe: true });
793
- }
794
-
795
- var objectGetOwnPropertyDescriptor = {};
796
-
797
- var objectPropertyIsEnumerable = {};
798
-
799
- var $propertyIsEnumerable = {}.propertyIsEnumerable;
800
- // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
801
- var getOwnPropertyDescriptor$2 = Object.getOwnPropertyDescriptor;
802
-
803
- // Nashorn ~ JDK8 bug
804
- var NASHORN_BUG = getOwnPropertyDescriptor$2 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
805
-
806
- // `Object.prototype.propertyIsEnumerable` method implementation
807
- // https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
808
- objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
809
- var descriptor = getOwnPropertyDescriptor$2(this, V);
810
- return !!descriptor && descriptor.enumerable;
811
- } : $propertyIsEnumerable;
812
-
813
- var uncurryThis$8 = functionUncurryThis;
814
- var fails$4 = fails$c;
815
- var classof$4 = classofRaw$2;
816
-
817
- var $Object = Object;
818
- var split = uncurryThis$8(''.split);
819
-
820
- // fallback for non-array-like ES3 and non-enumerable old V8 strings
821
- var indexedObject = fails$4(function () {
822
- // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
823
- // eslint-disable-next-line no-prototype-builtins -- safe
824
- return !$Object('z').propertyIsEnumerable(0);
825
- }) ? function (it) {
826
- return classof$4(it) === 'String' ? split(it, '') : $Object(it);
827
- } : $Object;
828
-
829
- // toObject with fallback for non-array-like ES3 strings
830
- var IndexedObject$1 = indexedObject;
831
- var requireObjectCoercible = requireObjectCoercible$2;
832
-
833
- var toIndexedObject$4 = function (it) {
834
- return IndexedObject$1(requireObjectCoercible(it));
835
- };
836
-
837
- var DESCRIPTORS$4 = descriptors;
838
- var call$8 = functionCall;
839
- var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
840
- var createPropertyDescriptor = createPropertyDescriptor$2;
841
- var toIndexedObject$3 = toIndexedObject$4;
842
- var toPropertyKey = toPropertyKey$2;
843
- var hasOwn$4 = hasOwnProperty_1;
844
- var IE8_DOM_DEFINE = ie8DomDefine;
845
-
846
- // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
847
- var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
848
-
849
- // `Object.getOwnPropertyDescriptor` method
850
- // https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
851
- objectGetOwnPropertyDescriptor.f = DESCRIPTORS$4 ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
852
- O = toIndexedObject$3(O);
853
- P = toPropertyKey(P);
854
- if (IE8_DOM_DEFINE) try {
855
- return $getOwnPropertyDescriptor(O, P);
856
- } catch (error) { /* empty */ }
857
- if (hasOwn$4(O, P)) return createPropertyDescriptor(!call$8(propertyIsEnumerableModule$1.f, O, P), O[P]);
858
- };
859
-
860
759
  var objectGetOwnPropertyNames = {};
861
760
 
862
761
  var ceil = Math.ceil;
@@ -908,19 +807,20 @@ var toLength = toLength$1;
908
807
 
909
808
  // `LengthOfArrayLike` abstract operation
910
809
  // https://tc39.es/ecma262/#sec-lengthofarraylike
911
- var lengthOfArrayLike$4 = function (obj) {
810
+ var lengthOfArrayLike$5 = function (obj) {
912
811
  return toLength(obj.length);
913
812
  };
914
813
 
915
814
  var toIndexedObject$2 = toIndexedObject$4;
916
815
  var toAbsoluteIndex = toAbsoluteIndex$1;
917
- var lengthOfArrayLike$3 = lengthOfArrayLike$4;
816
+ var lengthOfArrayLike$4 = lengthOfArrayLike$5;
918
817
 
919
818
  // `Array.prototype.{ indexOf, includes }` methods implementation
920
819
  var createMethod = function (IS_INCLUDES) {
921
820
  return function ($this, el, fromIndex) {
922
821
  var O = toIndexedObject$2($this);
923
- var length = lengthOfArrayLike$3(O);
822
+ var length = lengthOfArrayLike$4(O);
823
+ if (length === 0) return !IS_INCLUDES && -1;
924
824
  var index = toAbsoluteIndex(fromIndex, length);
925
825
  var value;
926
826
  // Array#includes uses SameValueZero equality algorithm
@@ -945,22 +845,22 @@ var arrayIncludes = {
945
845
  indexOf: createMethod(false)
946
846
  };
947
847
 
948
- var uncurryThis$7 = functionUncurryThis;
949
- var hasOwn$3 = hasOwnProperty_1;
848
+ var uncurryThis$8 = functionUncurryThis;
849
+ var hasOwn$7 = hasOwnProperty_1;
950
850
  var toIndexedObject$1 = toIndexedObject$4;
951
851
  var indexOf = arrayIncludes.indexOf;
952
852
  var hiddenKeys$2 = hiddenKeys$4;
953
853
 
954
- var push = uncurryThis$7([].push);
854
+ var push = uncurryThis$8([].push);
955
855
 
956
856
  var objectKeysInternal = function (object, names) {
957
857
  var O = toIndexedObject$1(object);
958
858
  var i = 0;
959
859
  var result = [];
960
860
  var key;
961
- for (key in O) !hasOwn$3(hiddenKeys$2, key) && hasOwn$3(O, key) && push(result, key);
861
+ for (key in O) !hasOwn$7(hiddenKeys$2, key) && hasOwn$7(O, key) && push(result, key);
962
862
  // Don't enum bug & hidden keys
963
- while (names.length > i) if (hasOwn$3(O, key = names[i++])) {
863
+ while (names.length > i) if (hasOwn$7(O, key = names[i++])) {
964
864
  ~indexOf(result, key) || push(result, key);
965
865
  }
966
866
  return result;
@@ -994,40 +894,40 @@ var objectGetOwnPropertySymbols = {};
994
894
  // eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
995
895
  objectGetOwnPropertySymbols.f = Object.getOwnPropertySymbols;
996
896
 
997
- var getBuiltIn$5 = getBuiltIn$7;
998
- var uncurryThis$6 = functionUncurryThis;
897
+ var getBuiltIn$6 = getBuiltIn$8;
898
+ var uncurryThis$7 = functionUncurryThis;
999
899
  var getOwnPropertyNamesModule = objectGetOwnPropertyNames;
1000
900
  var getOwnPropertySymbolsModule$1 = objectGetOwnPropertySymbols;
1001
- var anObject$8 = anObject$c;
901
+ var anObject$g = anObject$i;
1002
902
 
1003
- var concat$1 = uncurryThis$6([].concat);
903
+ var concat$1 = uncurryThis$7([].concat);
1004
904
 
1005
905
  // all object keys, includes non-enumerable and symbols
1006
- var ownKeys$1 = getBuiltIn$5('Reflect', 'ownKeys') || function ownKeys(it) {
1007
- var keys = getOwnPropertyNamesModule.f(anObject$8(it));
906
+ var ownKeys$1 = getBuiltIn$6('Reflect', 'ownKeys') || function ownKeys(it) {
907
+ var keys = getOwnPropertyNamesModule.f(anObject$g(it));
1008
908
  var getOwnPropertySymbols = getOwnPropertySymbolsModule$1.f;
1009
909
  return getOwnPropertySymbols ? concat$1(keys, getOwnPropertySymbols(it)) : keys;
1010
910
  };
1011
911
 
1012
- var hasOwn$2 = hasOwnProperty_1;
912
+ var hasOwn$6 = hasOwnProperty_1;
1013
913
  var ownKeys = ownKeys$1;
1014
914
  var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
1015
- var definePropertyModule$1 = objectDefineProperty;
915
+ var definePropertyModule$2 = objectDefineProperty;
1016
916
 
1017
- var copyConstructorProperties$1 = function (target, source, exceptions) {
917
+ var copyConstructorProperties$2 = function (target, source, exceptions) {
1018
918
  var keys = ownKeys(source);
1019
- var defineProperty = definePropertyModule$1.f;
919
+ var defineProperty = definePropertyModule$2.f;
1020
920
  var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
1021
921
  for (var i = 0; i < keys.length; i++) {
1022
922
  var key = keys[i];
1023
- if (!hasOwn$2(target, key) && !(exceptions && hasOwn$2(exceptions, key))) {
923
+ if (!hasOwn$6(target, key) && !(exceptions && hasOwn$6(exceptions, key))) {
1024
924
  defineProperty(target, key, getOwnPropertyDescriptor(source, key));
1025
925
  }
1026
926
  }
1027
927
  };
1028
928
 
1029
- var fails$3 = fails$c;
1030
- var isCallable$5 = isCallable$g;
929
+ var fails$9 = fails$h;
930
+ var isCallable$a = isCallable$k;
1031
931
 
1032
932
  var replacement = /#|\.prototype\./;
1033
933
 
@@ -1035,7 +935,7 @@ var isForced$2 = function (feature, detection) {
1035
935
  var value = data[normalize(feature)];
1036
936
  return value === POLYFILL ? true
1037
937
  : value === NATIVE ? false
1038
- : isCallable$5(detection) ? fails$3(detection)
938
+ : isCallable$a(detection) ? fails$9(detection)
1039
939
  : !!detection;
1040
940
  };
1041
941
 
@@ -1049,12 +949,12 @@ var POLYFILL = isForced$2.POLYFILL = 'P';
1049
949
 
1050
950
  var isForced_1 = isForced$2;
1051
951
 
1052
- var global$8 = global$i;
1053
- var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
1054
- var createNonEnumerableProperty = createNonEnumerableProperty$2;
1055
- var defineBuiltIn$2 = defineBuiltIn$4;
952
+ var global$a = global$j;
953
+ var getOwnPropertyDescriptor$2 = objectGetOwnPropertyDescriptor.f;
954
+ var createNonEnumerableProperty$4 = createNonEnumerableProperty$6;
955
+ var defineBuiltIn$5 = defineBuiltIn$6;
1056
956
  var defineGlobalProperty = defineGlobalProperty$3;
1057
- var copyConstructorProperties = copyConstructorProperties$1;
957
+ var copyConstructorProperties$1 = copyConstructorProperties$2;
1058
958
  var isForced$1 = isForced_1;
1059
959
 
1060
960
  /*
@@ -1078,32 +978,118 @@ var _export = function (options, source) {
1078
978
  var STATIC = options.stat;
1079
979
  var FORCED, target, key, targetProperty, sourceProperty, descriptor;
1080
980
  if (GLOBAL) {
1081
- target = global$8;
981
+ target = global$a;
1082
982
  } else if (STATIC) {
1083
- target = global$8[TARGET] || defineGlobalProperty(TARGET, {});
983
+ target = global$a[TARGET] || defineGlobalProperty(TARGET, {});
1084
984
  } else {
1085
- target = global$8[TARGET] && global$8[TARGET].prototype;
985
+ target = global$a[TARGET] && global$a[TARGET].prototype;
1086
986
  }
1087
987
  if (target) for (key in source) {
1088
988
  sourceProperty = source[key];
1089
989
  if (options.dontCallGetSet) {
1090
- descriptor = getOwnPropertyDescriptor$1(target, key);
990
+ descriptor = getOwnPropertyDescriptor$2(target, key);
1091
991
  targetProperty = descriptor && descriptor.value;
1092
992
  } else targetProperty = target[key];
1093
993
  FORCED = isForced$1(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
1094
994
  // contained in target
1095
995
  if (!FORCED && targetProperty !== undefined) {
1096
996
  if (typeof sourceProperty == typeof targetProperty) continue;
1097
- copyConstructorProperties(sourceProperty, targetProperty);
997
+ copyConstructorProperties$1(sourceProperty, targetProperty);
1098
998
  }
1099
999
  // add a flag to not completely full polyfills
1100
1000
  if (options.sham || (targetProperty && targetProperty.sham)) {
1101
- createNonEnumerableProperty(sourceProperty, 'sham', true);
1001
+ createNonEnumerableProperty$4(sourceProperty, 'sham', true);
1102
1002
  }
1103
- defineBuiltIn$2(target, key, sourceProperty, options);
1003
+ defineBuiltIn$5(target, key, sourceProperty, options);
1004
+ }
1005
+ };
1006
+
1007
+ var classof$5 = classofRaw$2;
1008
+
1009
+ // `IsArray` abstract operation
1010
+ // https://tc39.es/ecma262/#sec-isarray
1011
+ // eslint-disable-next-line es/no-array-isarray -- safe
1012
+ var isArray$3 = Array.isArray || function isArray(argument) {
1013
+ return classof$5(argument) === 'Array';
1014
+ };
1015
+
1016
+ var DESCRIPTORS$7 = descriptors;
1017
+ var isArray$2 = isArray$3;
1018
+
1019
+ var $TypeError$9 = TypeError;
1020
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
1021
+ var getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
1022
+
1023
+ // Safari < 13 does not throw an error in this case
1024
+ var SILENT_ON_NON_WRITABLE_LENGTH_SET = DESCRIPTORS$7 && !function () {
1025
+ // makes no sense without proper strict mode support
1026
+ if (this !== undefined) return true;
1027
+ try {
1028
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
1029
+ Object.defineProperty([], 'length', { writable: false }).length = 1;
1030
+ } catch (error) {
1031
+ return error instanceof TypeError;
1032
+ }
1033
+ }();
1034
+
1035
+ var arraySetLength = SILENT_ON_NON_WRITABLE_LENGTH_SET ? function (O, length) {
1036
+ if (isArray$2(O) && !getOwnPropertyDescriptor$1(O, 'length').writable) {
1037
+ throw new $TypeError$9('Cannot set read only .length');
1038
+ } return O.length = length;
1039
+ } : function (O, length) {
1040
+ return O.length = length;
1041
+ };
1042
+
1043
+ var $TypeError$8 = TypeError;
1044
+ var MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF; // 2 ** 53 - 1 == 9007199254740991
1045
+
1046
+ var doesNotExceedSafeInteger$2 = function (it) {
1047
+ if (it > MAX_SAFE_INTEGER) throw $TypeError$8('Maximum allowed index exceeded');
1048
+ return it;
1049
+ };
1050
+
1051
+ var $$e = _export;
1052
+ var toObject$3 = toObject$5;
1053
+ var lengthOfArrayLike$3 = lengthOfArrayLike$5;
1054
+ var setArrayLength = arraySetLength;
1055
+ var doesNotExceedSafeInteger$1 = doesNotExceedSafeInteger$2;
1056
+ var fails$8 = fails$h;
1057
+
1058
+ var INCORRECT_TO_LENGTH = fails$8(function () {
1059
+ return [].push.call({ length: 0x100000000 }, 1) !== 4294967297;
1060
+ });
1061
+
1062
+ // V8 <= 121 and Safari <= 15.4; FF < 23 throws InternalError
1063
+ // https://bugs.chromium.org/p/v8/issues/detail?id=12681
1064
+ var properErrorOnNonWritableLength = function () {
1065
+ try {
1066
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
1067
+ Object.defineProperty([], 'length', { writable: false }).push();
1068
+ } catch (error) {
1069
+ return error instanceof TypeError;
1104
1070
  }
1105
1071
  };
1106
1072
 
1073
+ var FORCED$2 = INCORRECT_TO_LENGTH || !properErrorOnNonWritableLength();
1074
+
1075
+ // `Array.prototype.push` method
1076
+ // https://tc39.es/ecma262/#sec-array.prototype.push
1077
+ $$e({ target: 'Array', proto: true, arity: 1, forced: FORCED$2 }, {
1078
+ // eslint-disable-next-line no-unused-vars -- required for `.length`
1079
+ push: function push(item) {
1080
+ var O = toObject$3(this);
1081
+ var len = lengthOfArrayLike$3(O);
1082
+ var argCount = arguments.length;
1083
+ doesNotExceedSafeInteger$1(len + argCount);
1084
+ for (var i = 0; i < argCount; i++) {
1085
+ O[len] = arguments[i];
1086
+ len++;
1087
+ }
1088
+ setArrayLength(O, len);
1089
+ return len;
1090
+ }
1091
+ });
1092
+
1107
1093
  var internalObjectKeys = objectKeysInternal;
1108
1094
  var enumBugKeys$1 = enumBugKeys$3;
1109
1095
 
@@ -1114,30 +1100,30 @@ var objectKeys$2 = Object.keys || function keys(O) {
1114
1100
  return internalObjectKeys(O, enumBugKeys$1);
1115
1101
  };
1116
1102
 
1117
- var DESCRIPTORS$3 = descriptors;
1118
- var uncurryThis$5 = functionUncurryThis;
1119
- var call$7 = functionCall;
1120
- var fails$2 = fails$c;
1103
+ var DESCRIPTORS$6 = descriptors;
1104
+ var uncurryThis$6 = functionUncurryThis;
1105
+ var call$d = functionCall;
1106
+ var fails$7 = fails$h;
1121
1107
  var objectKeys$1 = objectKeys$2;
1122
1108
  var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
1123
1109
  var propertyIsEnumerableModule = objectPropertyIsEnumerable;
1124
- var toObject$1 = toObject$3;
1110
+ var toObject$2 = toObject$5;
1125
1111
  var IndexedObject = indexedObject;
1126
1112
 
1127
1113
  // eslint-disable-next-line es/no-object-assign -- safe
1128
1114
  var $assign = Object.assign;
1129
1115
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
1130
- var defineProperty$3 = Object.defineProperty;
1131
- var concat = uncurryThis$5([].concat);
1116
+ var defineProperty$4 = Object.defineProperty;
1117
+ var concat = uncurryThis$6([].concat);
1132
1118
 
1133
1119
  // `Object.assign` method
1134
1120
  // https://tc39.es/ecma262/#sec-object.assign
1135
- var objectAssign = !$assign || fails$2(function () {
1121
+ var objectAssign = !$assign || fails$7(function () {
1136
1122
  // should have correct order of operations (Edge bug)
1137
- if (DESCRIPTORS$3 && $assign({ b: 1 }, $assign(defineProperty$3({}, 'a', {
1123
+ if (DESCRIPTORS$6 && $assign({ b: 1 }, $assign(defineProperty$4({}, 'a', {
1138
1124
  enumerable: true,
1139
1125
  get: function () {
1140
- defineProperty$3(this, 'b', {
1126
+ defineProperty$4(this, 'b', {
1141
1127
  value: 3,
1142
1128
  enumerable: false
1143
1129
  });
@@ -1153,7 +1139,7 @@ var objectAssign = !$assign || fails$2(function () {
1153
1139
  alphabet.split('').forEach(function (chr) { B[chr] = chr; });
1154
1140
  return $assign({}, A)[symbol] !== 7 || objectKeys$1($assign({}, B)).join('') !== alphabet;
1155
1141
  }) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`
1156
- var T = toObject$1(target);
1142
+ var T = toObject$2(target);
1157
1143
  var argumentsLength = arguments.length;
1158
1144
  var index = 1;
1159
1145
  var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
@@ -1166,112 +1152,811 @@ var objectAssign = !$assign || fails$2(function () {
1166
1152
  var key;
1167
1153
  while (length > j) {
1168
1154
  key = keys[j++];
1169
- if (!DESCRIPTORS$3 || call$7(propertyIsEnumerable, S, key)) T[key] = S[key];
1155
+ if (!DESCRIPTORS$6 || call$d(propertyIsEnumerable, S, key)) T[key] = S[key];
1170
1156
  }
1171
1157
  } return T;
1172
1158
  } : $assign;
1173
1159
 
1174
- var $$7 = _export;
1160
+ var $$d = _export;
1175
1161
  var assign = objectAssign;
1176
1162
 
1177
1163
  // `Object.assign` method
1178
1164
  // https://tc39.es/ecma262/#sec-object.assign
1179
1165
  // eslint-disable-next-line es/no-object-assign -- required for testing
1180
- $$7({ target: 'Object', stat: true, arity: 2, forced: Object.assign !== assign }, {
1166
+ $$d({ target: 'Object', stat: true, arity: 2, forced: Object.assign !== assign }, {
1181
1167
  assign: assign
1182
1168
  });
1183
1169
 
1184
- /**
1185
- * Creates a FetchPageFactory using the input ZohoFetchPageFetchFunction.
1186
- *
1187
- * @param fetch
1188
- * @param defaults
1189
- * @returns
1190
- */
1191
- function zohoFetchPageFactory(fetch$1, defaults) {
1192
- return fetch.fetchPageFactory(Object.assign({}, defaults, {
1193
- fetch: fetch$1,
1194
- readFetchPageResultInfo: function (result) {
1195
- var _result$info$more_rec, _result$info;
1196
- return {
1197
- hasNext: (_result$info$more_rec = (_result$info = result.info) == null ? void 0 : _result$info.more_records) != null ? _result$info$more_rec : false // if no info is returned, assume something wrong and there are no more records
1198
- };
1199
- },
1170
+ var wellKnownSymbol$d = wellKnownSymbol$f;
1200
1171
 
1201
- buildInputForNextPage: function (pageResult, input, options) {
1202
- var _options$maxItemsPerP;
1203
- return Object.assign({}, input, {
1204
- page: util.getNextPageNumber(pageResult),
1205
- per_page: (_options$maxItemsPerP = options.maxItemsPerPage) != null ? _options$maxItemsPerP : input.per_page
1206
- });
1172
+ var TO_STRING_TAG$4 = wellKnownSymbol$d('toStringTag');
1173
+ var test = {};
1174
+
1175
+ test[TO_STRING_TAG$4] = 'z';
1176
+
1177
+ var toStringTagSupport = String(test) === '[object z]';
1178
+
1179
+ var TO_STRING_TAG_SUPPORT = toStringTagSupport;
1180
+ var isCallable$9 = isCallable$k;
1181
+ var classofRaw$1 = classofRaw$2;
1182
+ var wellKnownSymbol$c = wellKnownSymbol$f;
1183
+
1184
+ var TO_STRING_TAG$3 = wellKnownSymbol$c('toStringTag');
1185
+ var $Object$1 = Object;
1186
+
1187
+ // ES3 wrong here
1188
+ var CORRECT_ARGUMENTS = classofRaw$1(function () { return arguments; }()) === 'Arguments';
1189
+
1190
+ // fallback for IE11 Script Access Denied error
1191
+ var tryGet = function (it, key) {
1192
+ try {
1193
+ return it[key];
1194
+ } catch (error) { /* empty */ }
1195
+ };
1196
+
1197
+ // getting tag from ES6+ `Object.prototype.toString`
1198
+ var classof$4 = TO_STRING_TAG_SUPPORT ? classofRaw$1 : function (it) {
1199
+ var O, tag, result;
1200
+ return it === undefined ? 'Undefined' : it === null ? 'Null'
1201
+ // @@toStringTag case
1202
+ : typeof (tag = tryGet(O = $Object$1(it), TO_STRING_TAG$3)) == 'string' ? tag
1203
+ // builtinTag case
1204
+ : CORRECT_ARGUMENTS ? classofRaw$1(O)
1205
+ // ES3 arguments fallback
1206
+ : (result = classofRaw$1(O)) === 'Object' && isCallable$9(O.callee) ? 'Arguments' : result;
1207
+ };
1208
+
1209
+ var classof$3 = classof$4;
1210
+
1211
+ var $String$1 = String;
1212
+
1213
+ var toString$1 = function (argument) {
1214
+ if (classof$3(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
1215
+ return $String$1(argument);
1216
+ };
1217
+
1218
+ var anObject$f = anObject$i;
1219
+
1220
+ // `RegExp.prototype.flags` getter implementation
1221
+ // https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
1222
+ var regexpFlags = function () {
1223
+ var that = anObject$f(this);
1224
+ var result = '';
1225
+ if (that.hasIndices) result += 'd';
1226
+ if (that.global) result += 'g';
1227
+ if (that.ignoreCase) result += 'i';
1228
+ if (that.multiline) result += 'm';
1229
+ if (that.dotAll) result += 's';
1230
+ if (that.unicode) result += 'u';
1231
+ if (that.unicodeSets) result += 'v';
1232
+ if (that.sticky) result += 'y';
1233
+ return result;
1234
+ };
1235
+
1236
+ var call$c = functionCall;
1237
+ var hasOwn$5 = hasOwnProperty_1;
1238
+ var isPrototypeOf$3 = objectIsPrototypeOf;
1239
+ var regExpFlags = regexpFlags;
1240
+
1241
+ var RegExpPrototype$1 = RegExp.prototype;
1242
+
1243
+ var regexpGetFlags = function (R) {
1244
+ var flags = R.flags;
1245
+ return flags === undefined && !('flags' in RegExpPrototype$1) && !hasOwn$5(R, 'flags') && isPrototypeOf$3(RegExpPrototype$1, R)
1246
+ ? call$c(regExpFlags, R) : flags;
1247
+ };
1248
+
1249
+ var PROPER_FUNCTION_NAME = functionName.PROPER;
1250
+ var defineBuiltIn$4 = defineBuiltIn$6;
1251
+ var anObject$e = anObject$i;
1252
+ var $toString = toString$1;
1253
+ var fails$6 = fails$h;
1254
+ var getRegExpFlags = regexpGetFlags;
1255
+
1256
+ var TO_STRING = 'toString';
1257
+ var RegExpPrototype = RegExp.prototype;
1258
+ var nativeToString = RegExpPrototype[TO_STRING];
1259
+
1260
+ var NOT_GENERIC = fails$6(function () { return nativeToString.call({ source: 'a', flags: 'b' }) !== '/a/b'; });
1261
+ // FF44- RegExp#toString has a wrong name
1262
+ var INCORRECT_NAME = PROPER_FUNCTION_NAME && nativeToString.name !== TO_STRING;
1263
+
1264
+ // `RegExp.prototype.toString` method
1265
+ // https://tc39.es/ecma262/#sec-regexp.prototype.tostring
1266
+ if (NOT_GENERIC || INCORRECT_NAME) {
1267
+ defineBuiltIn$4(RegExpPrototype, TO_STRING, function toString() {
1268
+ var R = anObject$e(this);
1269
+ var pattern = $toString(R.source);
1270
+ var flags = $toString(getRegExpFlags(R));
1271
+ return '/' + pattern + '/' + flags;
1272
+ }, { unsafe: true });
1273
+ }
1274
+
1275
+ var isPrototypeOf$2 = objectIsPrototypeOf;
1276
+
1277
+ var $TypeError$7 = TypeError;
1278
+
1279
+ var anInstance$2 = function (it, Prototype) {
1280
+ if (isPrototypeOf$2(Prototype, it)) return it;
1281
+ throw new $TypeError$7('Incorrect invocation');
1282
+ };
1283
+
1284
+ var fails$5 = fails$h;
1285
+
1286
+ var correctPrototypeGetter = !fails$5(function () {
1287
+ function F() { /* empty */ }
1288
+ F.prototype.constructor = null;
1289
+ // eslint-disable-next-line es/no-object-getprototypeof -- required for testing
1290
+ return Object.getPrototypeOf(new F()) !== F.prototype;
1291
+ });
1292
+
1293
+ var hasOwn$4 = hasOwnProperty_1;
1294
+ var isCallable$8 = isCallable$k;
1295
+ var toObject$1 = toObject$5;
1296
+ var sharedKey$1 = sharedKey$3;
1297
+ var CORRECT_PROTOTYPE_GETTER = correctPrototypeGetter;
1298
+
1299
+ var IE_PROTO$1 = sharedKey$1('IE_PROTO');
1300
+ var $Object = Object;
1301
+ var ObjectPrototype = $Object.prototype;
1302
+
1303
+ // `Object.getPrototypeOf` method
1304
+ // https://tc39.es/ecma262/#sec-object.getprototypeof
1305
+ // eslint-disable-next-line es/no-object-getprototypeof -- safe
1306
+ var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? $Object.getPrototypeOf : function (O) {
1307
+ var object = toObject$1(O);
1308
+ if (hasOwn$4(object, IE_PROTO$1)) return object[IE_PROTO$1];
1309
+ var constructor = object.constructor;
1310
+ if (isCallable$8(constructor) && object instanceof constructor) {
1311
+ return constructor.prototype;
1312
+ } return object instanceof $Object ? ObjectPrototype : null;
1313
+ };
1314
+
1315
+ var makeBuiltIn = makeBuiltInExports;
1316
+ var defineProperty$3 = objectDefineProperty;
1317
+
1318
+ var defineBuiltInAccessor$2 = function (target, name, descriptor) {
1319
+ if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });
1320
+ if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });
1321
+ return defineProperty$3.f(target, name, descriptor);
1322
+ };
1323
+
1324
+ var DESCRIPTORS$5 = descriptors;
1325
+ var definePropertyModule$1 = objectDefineProperty;
1326
+ var createPropertyDescriptor$1 = createPropertyDescriptor$4;
1327
+
1328
+ var createProperty$1 = function (object, key, value) {
1329
+ if (DESCRIPTORS$5) definePropertyModule$1.f(object, key, createPropertyDescriptor$1(0, value));
1330
+ else object[key] = value;
1331
+ };
1332
+
1333
+ var objectDefineProperties = {};
1334
+
1335
+ var DESCRIPTORS$4 = descriptors;
1336
+ var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
1337
+ var definePropertyModule = objectDefineProperty;
1338
+ var anObject$d = anObject$i;
1339
+ var toIndexedObject = toIndexedObject$4;
1340
+ var objectKeys = objectKeys$2;
1341
+
1342
+ // `Object.defineProperties` method
1343
+ // https://tc39.es/ecma262/#sec-object.defineproperties
1344
+ // eslint-disable-next-line es/no-object-defineproperties -- safe
1345
+ objectDefineProperties.f = DESCRIPTORS$4 && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
1346
+ anObject$d(O);
1347
+ var props = toIndexedObject(Properties);
1348
+ var keys = objectKeys(Properties);
1349
+ var length = keys.length;
1350
+ var index = 0;
1351
+ var key;
1352
+ while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);
1353
+ return O;
1354
+ };
1355
+
1356
+ var getBuiltIn$5 = getBuiltIn$8;
1357
+
1358
+ var html$2 = getBuiltIn$5('document', 'documentElement');
1359
+
1360
+ /* global ActiveXObject -- old IE, WSH */
1361
+ var anObject$c = anObject$i;
1362
+ var definePropertiesModule = objectDefineProperties;
1363
+ var enumBugKeys = enumBugKeys$3;
1364
+ var hiddenKeys = hiddenKeys$4;
1365
+ var html$1 = html$2;
1366
+ var documentCreateElement = documentCreateElement$1;
1367
+ var sharedKey = sharedKey$3;
1368
+
1369
+ var GT = '>';
1370
+ var LT = '<';
1371
+ var PROTOTYPE = 'prototype';
1372
+ var SCRIPT = 'script';
1373
+ var IE_PROTO = sharedKey('IE_PROTO');
1374
+
1375
+ var EmptyConstructor = function () { /* empty */ };
1376
+
1377
+ var scriptTag = function (content) {
1378
+ return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
1379
+ };
1380
+
1381
+ // Create object with fake `null` prototype: use ActiveX Object with cleared prototype
1382
+ var NullProtoObjectViaActiveX = function (activeXDocument) {
1383
+ activeXDocument.write(scriptTag(''));
1384
+ activeXDocument.close();
1385
+ var temp = activeXDocument.parentWindow.Object;
1386
+ activeXDocument = null; // avoid memory leak
1387
+ return temp;
1388
+ };
1389
+
1390
+ // Create object with fake `null` prototype: use iframe Object with cleared prototype
1391
+ var NullProtoObjectViaIFrame = function () {
1392
+ // Thrash, waste and sodomy: IE GC bug
1393
+ var iframe = documentCreateElement('iframe');
1394
+ var JS = 'java' + SCRIPT + ':';
1395
+ var iframeDocument;
1396
+ iframe.style.display = 'none';
1397
+ html$1.appendChild(iframe);
1398
+ // https://github.com/zloirock/core-js/issues/475
1399
+ iframe.src = String(JS);
1400
+ iframeDocument = iframe.contentWindow.document;
1401
+ iframeDocument.open();
1402
+ iframeDocument.write(scriptTag('document.F=Object'));
1403
+ iframeDocument.close();
1404
+ return iframeDocument.F;
1405
+ };
1406
+
1407
+ // Check for document.domain and active x support
1408
+ // No need to use active x approach when document.domain is not set
1409
+ // see https://github.com/es-shims/es5-shim/issues/150
1410
+ // variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
1411
+ // avoid IE GC bug
1412
+ var activeXDocument;
1413
+ var NullProtoObject = function () {
1414
+ try {
1415
+ activeXDocument = new ActiveXObject('htmlfile');
1416
+ } catch (error) { /* ignore */ }
1417
+ NullProtoObject = typeof document != 'undefined'
1418
+ ? document.domain && activeXDocument
1419
+ ? NullProtoObjectViaActiveX(activeXDocument) // old IE
1420
+ : NullProtoObjectViaIFrame()
1421
+ : NullProtoObjectViaActiveX(activeXDocument); // WSH
1422
+ var length = enumBugKeys.length;
1423
+ while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
1424
+ return NullProtoObject();
1425
+ };
1426
+
1427
+ hiddenKeys[IE_PROTO] = true;
1428
+
1429
+ // `Object.create` method
1430
+ // https://tc39.es/ecma262/#sec-object.create
1431
+ // eslint-disable-next-line es/no-object-create -- safe
1432
+ var objectCreate = Object.create || function create(O, Properties) {
1433
+ var result;
1434
+ if (O !== null) {
1435
+ EmptyConstructor[PROTOTYPE] = anObject$c(O);
1436
+ result = new EmptyConstructor();
1437
+ EmptyConstructor[PROTOTYPE] = null;
1438
+ // add "__proto__" for Object.getPrototypeOf polyfill
1439
+ result[IE_PROTO] = O;
1440
+ } else result = NullProtoObject();
1441
+ return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
1442
+ };
1443
+
1444
+ var fails$4 = fails$h;
1445
+ var isCallable$7 = isCallable$k;
1446
+ var isObject$7 = isObject$d;
1447
+ var getPrototypeOf$1 = objectGetPrototypeOf;
1448
+ var defineBuiltIn$3 = defineBuiltIn$6;
1449
+ var wellKnownSymbol$b = wellKnownSymbol$f;
1450
+
1451
+ var ITERATOR$4 = wellKnownSymbol$b('iterator');
1452
+ var BUGGY_SAFARI_ITERATORS = false;
1453
+
1454
+ // `%IteratorPrototype%` object
1455
+ // https://tc39.es/ecma262/#sec-%iteratorprototype%-object
1456
+ var IteratorPrototype$2, PrototypeOfArrayIteratorPrototype, arrayIterator;
1457
+
1458
+ /* eslint-disable es/no-array-prototype-keys -- safe */
1459
+ if ([].keys) {
1460
+ arrayIterator = [].keys();
1461
+ // Safari 8 has buggy iterators w/o `next`
1462
+ if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;
1463
+ else {
1464
+ PrototypeOfArrayIteratorPrototype = getPrototypeOf$1(getPrototypeOf$1(arrayIterator));
1465
+ if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype$2 = PrototypeOfArrayIteratorPrototype;
1466
+ }
1467
+ }
1468
+
1469
+ var NEW_ITERATOR_PROTOTYPE = !isObject$7(IteratorPrototype$2) || fails$4(function () {
1470
+ var test = {};
1471
+ // FF44- legacy iterators case
1472
+ return IteratorPrototype$2[ITERATOR$4].call(test) !== test;
1473
+ });
1474
+
1475
+ if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype$2 = {};
1476
+
1477
+ // `%IteratorPrototype%[@@iterator]()` method
1478
+ // https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
1479
+ if (!isCallable$7(IteratorPrototype$2[ITERATOR$4])) {
1480
+ defineBuiltIn$3(IteratorPrototype$2, ITERATOR$4, function () {
1481
+ return this;
1482
+ });
1483
+ }
1484
+
1485
+ var iteratorsCore = {
1486
+ IteratorPrototype: IteratorPrototype$2,
1487
+ BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS
1488
+ };
1489
+
1490
+ var $$c = _export;
1491
+ var global$9 = global$j;
1492
+ var anInstance$1 = anInstance$2;
1493
+ var anObject$b = anObject$i;
1494
+ var isCallable$6 = isCallable$k;
1495
+ var getPrototypeOf = objectGetPrototypeOf;
1496
+ var defineBuiltInAccessor$1 = defineBuiltInAccessor$2;
1497
+ var createProperty = createProperty$1;
1498
+ var fails$3 = fails$h;
1499
+ var hasOwn$3 = hasOwnProperty_1;
1500
+ var wellKnownSymbol$a = wellKnownSymbol$f;
1501
+ var IteratorPrototype$1 = iteratorsCore.IteratorPrototype;
1502
+ var DESCRIPTORS$3 = descriptors;
1503
+
1504
+ var CONSTRUCTOR = 'constructor';
1505
+ var ITERATOR$3 = 'Iterator';
1506
+ var TO_STRING_TAG$2 = wellKnownSymbol$a('toStringTag');
1507
+
1508
+ var $TypeError$6 = TypeError;
1509
+ var NativeIterator = global$9[ITERATOR$3];
1510
+
1511
+ // FF56- have non-standard global helper `Iterator`
1512
+ var FORCED$1 = !isCallable$6(NativeIterator)
1513
+ || NativeIterator.prototype !== IteratorPrototype$1
1514
+ // FF44- non-standard `Iterator` passes previous tests
1515
+ || !fails$3(function () { NativeIterator({}); });
1516
+
1517
+ var IteratorConstructor = function Iterator() {
1518
+ anInstance$1(this, IteratorPrototype$1);
1519
+ if (getPrototypeOf(this) === IteratorPrototype$1) throw new $TypeError$6('Abstract class Iterator not directly constructable');
1520
+ };
1521
+
1522
+ var defineIteratorPrototypeAccessor = function (key, value) {
1523
+ if (DESCRIPTORS$3) {
1524
+ defineBuiltInAccessor$1(IteratorPrototype$1, key, {
1525
+ configurable: true,
1526
+ get: function () {
1527
+ return value;
1528
+ },
1529
+ set: function (replacement) {
1530
+ anObject$b(this);
1531
+ if (this === IteratorPrototype$1) throw new $TypeError$6("You can't redefine this property");
1532
+ if (hasOwn$3(this, key)) this[key] = replacement;
1533
+ else createProperty(this, key, replacement);
1534
+ }
1535
+ });
1536
+ } else IteratorPrototype$1[key] = value;
1537
+ };
1538
+
1539
+ if (!hasOwn$3(IteratorPrototype$1, TO_STRING_TAG$2)) defineIteratorPrototypeAccessor(TO_STRING_TAG$2, ITERATOR$3);
1540
+
1541
+ if (FORCED$1 || !hasOwn$3(IteratorPrototype$1, CONSTRUCTOR) || IteratorPrototype$1[CONSTRUCTOR] === Object) {
1542
+ defineIteratorPrototypeAccessor(CONSTRUCTOR, IteratorConstructor);
1543
+ }
1544
+
1545
+ IteratorConstructor.prototype = IteratorPrototype$1;
1546
+
1547
+ // `Iterator` constructor
1548
+ // https://github.com/tc39/proposal-iterator-helpers
1549
+ $$c({ global: true, constructor: true, forced: FORCED$1 }, {
1550
+ Iterator: IteratorConstructor
1551
+ });
1552
+
1553
+ // `GetIteratorDirect(obj)` abstract operation
1554
+ // https://tc39.es/proposal-iterator-helpers/#sec-getiteratordirect
1555
+ var getIteratorDirect$5 = function (obj) {
1556
+ return {
1557
+ iterator: obj,
1558
+ next: obj.next,
1559
+ done: false
1560
+ };
1561
+ };
1562
+
1563
+ var defineBuiltIn$2 = defineBuiltIn$6;
1564
+
1565
+ var defineBuiltIns$1 = function (target, src, options) {
1566
+ for (var key in src) defineBuiltIn$2(target, key, src[key], options);
1567
+ return target;
1568
+ };
1569
+
1570
+ // `CreateIterResultObject` abstract operation
1571
+ // https://tc39.es/ecma262/#sec-createiterresultobject
1572
+ var createIterResultObject$1 = function (value, done) {
1573
+ return { value: value, done: done };
1574
+ };
1575
+
1576
+ var call$b = functionCall;
1577
+ var anObject$a = anObject$i;
1578
+ var getMethod$2 = getMethod$4;
1579
+
1580
+ var iteratorClose$4 = function (iterator, kind, value) {
1581
+ var innerResult, innerError;
1582
+ anObject$a(iterator);
1583
+ try {
1584
+ innerResult = getMethod$2(iterator, 'return');
1585
+ if (!innerResult) {
1586
+ if (kind === 'throw') throw value;
1587
+ return value;
1588
+ }
1589
+ innerResult = call$b(innerResult, iterator);
1590
+ } catch (error) {
1591
+ innerError = true;
1592
+ innerResult = error;
1593
+ }
1594
+ if (kind === 'throw') throw value;
1595
+ if (innerError) throw innerResult;
1596
+ anObject$a(innerResult);
1597
+ return value;
1598
+ };
1599
+
1600
+ var call$a = functionCall;
1601
+ var create$1 = objectCreate;
1602
+ var createNonEnumerableProperty$3 = createNonEnumerableProperty$6;
1603
+ var defineBuiltIns = defineBuiltIns$1;
1604
+ var wellKnownSymbol$9 = wellKnownSymbol$f;
1605
+ var InternalStateModule$1 = internalState;
1606
+ var getMethod$1 = getMethod$4;
1607
+ var IteratorPrototype = iteratorsCore.IteratorPrototype;
1608
+ var createIterResultObject = createIterResultObject$1;
1609
+ var iteratorClose$3 = iteratorClose$4;
1610
+
1611
+ var TO_STRING_TAG$1 = wellKnownSymbol$9('toStringTag');
1612
+ var ITERATOR_HELPER = 'IteratorHelper';
1613
+ var WRAP_FOR_VALID_ITERATOR = 'WrapForValidIterator';
1614
+ var setInternalState$1 = InternalStateModule$1.set;
1615
+
1616
+ var createIteratorProxyPrototype = function (IS_ITERATOR) {
1617
+ var getInternalState = InternalStateModule$1.getterFor(IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER);
1618
+
1619
+ return defineBuiltIns(create$1(IteratorPrototype), {
1620
+ next: function next() {
1621
+ var state = getInternalState(this);
1622
+ // for simplification:
1623
+ // for `%WrapForValidIteratorPrototype%.next` our `nextHandler` returns `IterResultObject`
1624
+ // for `%IteratorHelperPrototype%.next` - just a value
1625
+ if (IS_ITERATOR) return state.nextHandler();
1626
+ try {
1627
+ var result = state.done ? undefined : state.nextHandler();
1628
+ return createIterResultObject(result, state.done);
1629
+ } catch (error) {
1630
+ state.done = true;
1631
+ throw error;
1632
+ }
1633
+ },
1634
+ 'return': function () {
1635
+ var state = getInternalState(this);
1636
+ var iterator = state.iterator;
1637
+ state.done = true;
1638
+ if (IS_ITERATOR) {
1639
+ var returnMethod = getMethod$1(iterator, 'return');
1640
+ return returnMethod ? call$a(returnMethod, iterator) : createIterResultObject(undefined, true);
1641
+ }
1642
+ if (state.inner) try {
1643
+ iteratorClose$3(state.inner.iterator, 'normal');
1644
+ } catch (error) {
1645
+ return iteratorClose$3(iterator, 'throw', error);
1646
+ }
1647
+ iteratorClose$3(iterator, 'normal');
1648
+ return createIterResultObject(undefined, true);
1207
1649
  }
1208
- }));
1209
- }
1650
+ });
1651
+ };
1210
1652
 
1211
- const ZOHO_RECRUIT_SERVICE_NAME = 'recruit';
1212
- function zohoRecruitConfigApiUrl(input) {
1213
- switch (input) {
1214
- case 'sandbox':
1215
- return 'https://recruitsandbox.zoho.com/recruit';
1216
- case 'production':
1217
- return 'https://recruit.zoho.com/recruit';
1218
- default:
1219
- return input;
1220
- }
1221
- }
1653
+ var WrapForValidIteratorPrototype = createIteratorProxyPrototype(true);
1654
+ var IteratorHelperPrototype = createIteratorProxyPrototype(false);
1655
+
1656
+ createNonEnumerableProperty$3(IteratorHelperPrototype, TO_STRING_TAG$1, 'Iterator Helper');
1657
+
1658
+ var iteratorCreateProxy = function (nextHandler, IS_ITERATOR) {
1659
+ var IteratorProxy = function Iterator(record, state) {
1660
+ if (state) {
1661
+ state.iterator = record.iterator;
1662
+ state.next = record.next;
1663
+ } else state = record;
1664
+ state.type = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER;
1665
+ state.nextHandler = nextHandler;
1666
+ state.counter = 0;
1667
+ state.done = false;
1668
+ setInternalState$1(this, state);
1669
+ };
1222
1670
 
1223
- var classof$3 = classofRaw$2;
1671
+ IteratorProxy.prototype = IS_ITERATOR ? WrapForValidIteratorPrototype : IteratorHelperPrototype;
1224
1672
 
1225
- // `IsArray` abstract operation
1226
- // https://tc39.es/ecma262/#sec-isarray
1227
- // eslint-disable-next-line es/no-array-isarray -- safe
1228
- var isArray$2 = Array.isArray || function isArray(argument) {
1229
- return classof$3(argument) === 'Array';
1673
+ return IteratorProxy;
1230
1674
  };
1231
1675
 
1232
- var $TypeError$7 = TypeError;
1233
- var MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF; // 2 ** 53 - 1 == 9007199254740991
1676
+ var anObject$9 = anObject$i;
1677
+ var iteratorClose$2 = iteratorClose$4;
1234
1678
 
1235
- var doesNotExceedSafeInteger$1 = function (it) {
1236
- if (it > MAX_SAFE_INTEGER) throw $TypeError$7('Maximum allowed index exceeded');
1237
- return it;
1679
+ // call something on iterator step with safe closing on error
1680
+ var callWithSafeIterationClosing$2 = function (iterator, fn, value, ENTRIES) {
1681
+ try {
1682
+ return ENTRIES ? fn(anObject$9(value)[0], value[1]) : fn(value);
1683
+ } catch (error) {
1684
+ iteratorClose$2(iterator, 'throw', error);
1685
+ }
1238
1686
  };
1239
1687
 
1688
+ var $$b = _export;
1689
+ var call$9 = functionCall;
1690
+ var aCallable$b = aCallable$d;
1691
+ var anObject$8 = anObject$i;
1692
+ var getIteratorDirect$4 = getIteratorDirect$5;
1693
+ var createIteratorProxy$2 = iteratorCreateProxy;
1694
+ var callWithSafeIterationClosing$1 = callWithSafeIterationClosing$2;
1695
+ var IS_PURE$2 = isPure;
1696
+
1697
+ var IteratorProxy$2 = createIteratorProxy$2(function () {
1698
+ var iterator = this.iterator;
1699
+ var predicate = this.predicate;
1700
+ var next = this.next;
1701
+ var result, done, value;
1702
+ while (true) {
1703
+ result = anObject$8(call$9(next, iterator));
1704
+ done = this.done = !!result.done;
1705
+ if (done) return;
1706
+ value = result.value;
1707
+ if (callWithSafeIterationClosing$1(iterator, predicate, [value, this.counter++], true)) return value;
1708
+ }
1709
+ });
1710
+
1711
+ // `Iterator.prototype.filter` method
1712
+ // https://github.com/tc39/proposal-iterator-helpers
1713
+ $$b({ target: 'Iterator', proto: true, real: true, forced: IS_PURE$2 }, {
1714
+ filter: function filter(predicate) {
1715
+ anObject$8(this);
1716
+ aCallable$b(predicate);
1717
+ return new IteratorProxy$2(getIteratorDirect$4(this), {
1718
+ predicate: predicate
1719
+ });
1720
+ }
1721
+ });
1722
+
1240
1723
  var classofRaw = classofRaw$2;
1241
- var uncurryThis$4 = functionUncurryThis;
1724
+ var uncurryThis$5 = functionUncurryThis;
1242
1725
 
1243
1726
  var functionUncurryThisClause = function (fn) {
1244
1727
  // Nashorn bug:
1245
1728
  // https://github.com/zloirock/core-js/issues/1128
1246
1729
  // https://github.com/zloirock/core-js/issues/1130
1247
- if (classofRaw(fn) === 'Function') return uncurryThis$4(fn);
1730
+ if (classofRaw(fn) === 'Function') return uncurryThis$5(fn);
1248
1731
  };
1249
1732
 
1250
- var uncurryThis$3 = functionUncurryThisClause;
1251
- var aCallable$7 = aCallable$9;
1733
+ var uncurryThis$4 = functionUncurryThisClause;
1734
+ var aCallable$a = aCallable$d;
1252
1735
  var NATIVE_BIND$1 = functionBindNative;
1253
1736
 
1254
- var bind$5 = uncurryThis$3(uncurryThis$3.bind);
1737
+ var bind$5 = uncurryThis$4(uncurryThis$4.bind);
1255
1738
 
1256
1739
  // optional / simple context binding
1257
1740
  var functionBindContext = function (fn, that) {
1258
- aCallable$7(fn);
1741
+ aCallable$a(fn);
1259
1742
  return that === undefined ? fn : NATIVE_BIND$1 ? bind$5(fn, that) : function (/* ...args */) {
1260
1743
  return fn.apply(that, arguments);
1261
1744
  };
1262
1745
  };
1263
1746
 
1264
- var isArray$1 = isArray$2;
1265
- var lengthOfArrayLike$2 = lengthOfArrayLike$4;
1266
- var doesNotExceedSafeInteger = doesNotExceedSafeInteger$1;
1747
+ var iterators = {};
1748
+
1749
+ var wellKnownSymbol$8 = wellKnownSymbol$f;
1750
+ var Iterators$1 = iterators;
1751
+
1752
+ var ITERATOR$2 = wellKnownSymbol$8('iterator');
1753
+ var ArrayPrototype$1 = Array.prototype;
1754
+
1755
+ // check on default Array iterator
1756
+ var isArrayIteratorMethod$1 = function (it) {
1757
+ return it !== undefined && (Iterators$1.Array === it || ArrayPrototype$1[ITERATOR$2] === it);
1758
+ };
1759
+
1760
+ var classof$2 = classof$4;
1761
+ var getMethod = getMethod$4;
1762
+ var isNullOrUndefined$1 = isNullOrUndefined$4;
1763
+ var Iterators = iterators;
1764
+ var wellKnownSymbol$7 = wellKnownSymbol$f;
1765
+
1766
+ var ITERATOR$1 = wellKnownSymbol$7('iterator');
1767
+
1768
+ var getIteratorMethod$3 = function (it) {
1769
+ if (!isNullOrUndefined$1(it)) return getMethod(it, ITERATOR$1)
1770
+ || getMethod(it, '@@iterator')
1771
+ || Iterators[classof$2(it)];
1772
+ };
1773
+
1774
+ var call$8 = functionCall;
1775
+ var aCallable$9 = aCallable$d;
1776
+ var anObject$7 = anObject$i;
1777
+ var tryToString$2 = tryToString$4;
1778
+ var getIteratorMethod$2 = getIteratorMethod$3;
1779
+
1780
+ var $TypeError$5 = TypeError;
1781
+
1782
+ var getIterator$1 = function (argument, usingIterator) {
1783
+ var iteratorMethod = arguments.length < 2 ? getIteratorMethod$2(argument) : usingIterator;
1784
+ if (aCallable$9(iteratorMethod)) return anObject$7(call$8(iteratorMethod, argument));
1785
+ throw new $TypeError$5(tryToString$2(argument) + ' is not iterable');
1786
+ };
1787
+
1267
1788
  var bind$4 = functionBindContext;
1789
+ var call$7 = functionCall;
1790
+ var anObject$6 = anObject$i;
1791
+ var tryToString$1 = tryToString$4;
1792
+ var isArrayIteratorMethod = isArrayIteratorMethod$1;
1793
+ var lengthOfArrayLike$2 = lengthOfArrayLike$5;
1794
+ var isPrototypeOf$1 = objectIsPrototypeOf;
1795
+ var getIterator = getIterator$1;
1796
+ var getIteratorMethod$1 = getIteratorMethod$3;
1797
+ var iteratorClose$1 = iteratorClose$4;
1798
+
1799
+ var $TypeError$4 = TypeError;
1800
+
1801
+ var Result = function (stopped, result) {
1802
+ this.stopped = stopped;
1803
+ this.result = result;
1804
+ };
1805
+
1806
+ var ResultPrototype = Result.prototype;
1807
+
1808
+ var iterate$3 = function (iterable, unboundFunction, options) {
1809
+ var that = options && options.that;
1810
+ var AS_ENTRIES = !!(options && options.AS_ENTRIES);
1811
+ var IS_RECORD = !!(options && options.IS_RECORD);
1812
+ var IS_ITERATOR = !!(options && options.IS_ITERATOR);
1813
+ var INTERRUPTED = !!(options && options.INTERRUPTED);
1814
+ var fn = bind$4(unboundFunction, that);
1815
+ var iterator, iterFn, index, length, result, next, step;
1816
+
1817
+ var stop = function (condition) {
1818
+ if (iterator) iteratorClose$1(iterator, 'normal', condition);
1819
+ return new Result(true, condition);
1820
+ };
1821
+
1822
+ var callFn = function (value) {
1823
+ if (AS_ENTRIES) {
1824
+ anObject$6(value);
1825
+ return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
1826
+ } return INTERRUPTED ? fn(value, stop) : fn(value);
1827
+ };
1828
+
1829
+ if (IS_RECORD) {
1830
+ iterator = iterable.iterator;
1831
+ } else if (IS_ITERATOR) {
1832
+ iterator = iterable;
1833
+ } else {
1834
+ iterFn = getIteratorMethod$1(iterable);
1835
+ if (!iterFn) throw new $TypeError$4(tryToString$1(iterable) + ' is not iterable');
1836
+ // optimisation for array iterators
1837
+ if (isArrayIteratorMethod(iterFn)) {
1838
+ for (index = 0, length = lengthOfArrayLike$2(iterable); length > index; index++) {
1839
+ result = callFn(iterable[index]);
1840
+ if (result && isPrototypeOf$1(ResultPrototype, result)) return result;
1841
+ } return new Result(false);
1842
+ }
1843
+ iterator = getIterator(iterable, iterFn);
1844
+ }
1845
+
1846
+ next = IS_RECORD ? iterable.next : iterator.next;
1847
+ while (!(step = call$7(next, iterator)).done) {
1848
+ try {
1849
+ result = callFn(step.value);
1850
+ } catch (error) {
1851
+ iteratorClose$1(iterator, 'throw', error);
1852
+ }
1853
+ if (typeof result == 'object' && result && isPrototypeOf$1(ResultPrototype, result)) return result;
1854
+ } return new Result(false);
1855
+ };
1856
+
1857
+ var $$a = _export;
1858
+ var iterate$2 = iterate$3;
1859
+ var aCallable$8 = aCallable$d;
1860
+ var anObject$5 = anObject$i;
1861
+ var getIteratorDirect$3 = getIteratorDirect$5;
1862
+
1863
+ // `Iterator.prototype.forEach` method
1864
+ // https://github.com/tc39/proposal-iterator-helpers
1865
+ $$a({ target: 'Iterator', proto: true, real: true }, {
1866
+ forEach: function forEach(fn) {
1867
+ anObject$5(this);
1868
+ aCallable$8(fn);
1869
+ var record = getIteratorDirect$3(this);
1870
+ var counter = 0;
1871
+ iterate$2(record, function (value) {
1872
+ fn(value, counter++);
1873
+ }, { IS_RECORD: true });
1874
+ }
1875
+ });
1876
+
1877
+ var call$6 = functionCall;
1878
+ var aCallable$7 = aCallable$d;
1879
+ var anObject$4 = anObject$i;
1880
+ var getIteratorDirect$2 = getIteratorDirect$5;
1881
+ var createIteratorProxy$1 = iteratorCreateProxy;
1882
+ var callWithSafeIterationClosing = callWithSafeIterationClosing$2;
1883
+
1884
+ var IteratorProxy$1 = createIteratorProxy$1(function () {
1885
+ var iterator = this.iterator;
1886
+ var result = anObject$4(call$6(this.next, iterator));
1887
+ var done = this.done = !!result.done;
1888
+ if (!done) return callWithSafeIterationClosing(iterator, this.mapper, [result.value, this.counter++], true);
1889
+ });
1890
+
1891
+ // `Iterator.prototype.map` method
1892
+ // https://github.com/tc39/proposal-iterator-helpers
1893
+ var iteratorMap = function map(mapper) {
1894
+ anObject$4(this);
1895
+ aCallable$7(mapper);
1896
+ return new IteratorProxy$1(getIteratorDirect$2(this), {
1897
+ mapper: mapper
1898
+ });
1899
+ };
1900
+
1901
+ var $$9 = _export;
1902
+ var map = iteratorMap;
1903
+ var IS_PURE$1 = isPure;
1904
+
1905
+ // `Iterator.prototype.map` method
1906
+ // https://github.com/tc39/proposal-iterator-helpers
1907
+ $$9({ target: 'Iterator', proto: true, real: true, forced: IS_PURE$1 }, {
1908
+ map: map
1909
+ });
1910
+
1911
+ /**
1912
+ * Creates a FetchPageFactory using the input ZohoFetchPageFetchFunction.
1913
+ *
1914
+ * @param fetch
1915
+ * @param defaults
1916
+ * @returns
1917
+ */
1918
+ function zohoFetchPageFactory(fetch$1, defaults) {
1919
+ return fetch.fetchPageFactory(Object.assign({}, defaults, {
1920
+ fetch: fetch$1,
1921
+ readFetchPageResultInfo: function (result) {
1922
+ var _result$info$more_rec, _result$info;
1923
+ return {
1924
+ hasNext: (_result$info$more_rec = (_result$info = result.info) == null ? void 0 : _result$info.more_records) != null ? _result$info$more_rec : false // if no info is returned, assume something wrong and there are no more records
1925
+ };
1926
+ },
1927
+ buildInputForNextPage: function (pageResult, input, options) {
1928
+ var _options$maxItemsPerP;
1929
+ return Object.assign({}, input, {
1930
+ page: util.getNextPageNumber(pageResult),
1931
+ per_page: (_options$maxItemsPerP = options.maxItemsPerPage) != null ? _options$maxItemsPerP : input.per_page
1932
+ });
1933
+ }
1934
+ }));
1935
+ }
1936
+
1937
+ const ZOHO_RECRUIT_SERVICE_NAME = 'recruit';
1938
+ function zohoRecruitConfigApiUrl(input) {
1939
+ switch (input) {
1940
+ case 'sandbox':
1941
+ return 'https://recruitsandbox.zoho.com/recruit';
1942
+ case 'production':
1943
+ return 'https://recruit.zoho.com/recruit';
1944
+ default:
1945
+ return input;
1946
+ }
1947
+ }
1948
+
1949
+ var isArray$1 = isArray$3;
1950
+ var lengthOfArrayLike$1 = lengthOfArrayLike$5;
1951
+ var doesNotExceedSafeInteger = doesNotExceedSafeInteger$2;
1952
+ var bind$3 = functionBindContext;
1268
1953
 
1269
1954
  // `FlattenIntoArray` abstract operation
1270
1955
  // https://tc39.github.io/proposal-flatMap/#sec-FlattenIntoArray
1271
1956
  var flattenIntoArray$1 = function (target, original, source, sourceLen, start, depth, mapper, thisArg) {
1272
1957
  var targetIndex = start;
1273
1958
  var sourceIndex = 0;
1274
- var mapFn = mapper ? bind$4(mapper, thisArg) : false;
1959
+ var mapFn = mapper ? bind$3(mapper, thisArg) : false;
1275
1960
  var element, elementLen;
1276
1961
 
1277
1962
  while (sourceIndex < sourceLen) {
@@ -1279,7 +1964,7 @@ var flattenIntoArray$1 = function (target, original, source, sourceLen, start, d
1279
1964
  element = mapFn ? mapFn(source[sourceIndex], sourceIndex, original) : source[sourceIndex];
1280
1965
 
1281
1966
  if (depth > 0 && isArray$1(element)) {
1282
- elementLen = lengthOfArrayLike$2(element);
1967
+ elementLen = lengthOfArrayLike$1(element);
1283
1968
  targetIndex = flattenIntoArray$1(target, original, element, elementLen, targetIndex, depth - 1) - 1;
1284
1969
  } else {
1285
1970
  doesNotExceedSafeInteger(targetIndex + 1);
@@ -1295,21 +1980,21 @@ var flattenIntoArray$1 = function (target, original, source, sourceLen, start, d
1295
1980
 
1296
1981
  var flattenIntoArray_1 = flattenIntoArray$1;
1297
1982
 
1298
- var uncurryThis$2 = functionUncurryThis;
1299
- var fails$1 = fails$c;
1300
- var isCallable$4 = isCallable$g;
1301
- var classof$2 = classof$6;
1302
- var getBuiltIn$4 = getBuiltIn$7;
1983
+ var uncurryThis$3 = functionUncurryThis;
1984
+ var fails$2 = fails$h;
1985
+ var isCallable$5 = isCallable$k;
1986
+ var classof$1 = classof$4;
1987
+ var getBuiltIn$4 = getBuiltIn$8;
1303
1988
  var inspectSource$1 = inspectSource$3;
1304
1989
 
1305
1990
  var noop = function () { /* empty */ };
1306
1991
  var construct = getBuiltIn$4('Reflect', 'construct');
1307
1992
  var constructorRegExp = /^\s*(?:class|function)\b/;
1308
- var exec = uncurryThis$2(constructorRegExp.exec);
1993
+ var exec = uncurryThis$3(constructorRegExp.exec);
1309
1994
  var INCORRECT_TO_STRING = !constructorRegExp.test(noop);
1310
1995
 
1311
1996
  var isConstructorModern = function isConstructor(argument) {
1312
- if (!isCallable$4(argument)) return false;
1997
+ if (!isCallable$5(argument)) return false;
1313
1998
  try {
1314
1999
  construct(noop, [], argument);
1315
2000
  return true;
@@ -1319,8 +2004,8 @@ var isConstructorModern = function isConstructor(argument) {
1319
2004
  };
1320
2005
 
1321
2006
  var isConstructorLegacy = function isConstructor(argument) {
1322
- if (!isCallable$4(argument)) return false;
1323
- switch (classof$2(argument)) {
2007
+ if (!isCallable$5(argument)) return false;
2008
+ switch (classof$1(argument)) {
1324
2009
  case 'AsyncFunction':
1325
2010
  case 'GeneratorFunction':
1326
2011
  case 'AsyncGeneratorFunction': return false;
@@ -1339,188 +2024,77 @@ isConstructorLegacy.sham = true;
1339
2024
 
1340
2025
  // `IsConstructor` abstract operation
1341
2026
  // https://tc39.es/ecma262/#sec-isconstructor
1342
- var isConstructor$2 = !construct || fails$1(function () {
2027
+ var isConstructor$2 = !construct || fails$2(function () {
1343
2028
  var called;
1344
2029
  return isConstructorModern(isConstructorModern.call)
1345
2030
  || !isConstructorModern(Object)
1346
2031
  || !isConstructorModern(function () { called = true; })
1347
2032
  || called;
1348
- }) ? isConstructorLegacy : isConstructorModern;
1349
-
1350
- var isArray = isArray$2;
1351
- var isConstructor$1 = isConstructor$2;
1352
- var isObject$3 = isObject$9;
1353
- var wellKnownSymbol$8 = wellKnownSymbol$c;
1354
-
1355
- var SPECIES$3 = wellKnownSymbol$8('species');
1356
- var $Array = Array;
1357
-
1358
- // a part of `ArraySpeciesCreate` abstract operation
1359
- // https://tc39.es/ecma262/#sec-arrayspeciescreate
1360
- var arraySpeciesConstructor$1 = function (originalArray) {
1361
- var C;
1362
- if (isArray(originalArray)) {
1363
- C = originalArray.constructor;
1364
- // cross-realm fallback
1365
- if (isConstructor$1(C) && (C === $Array || isArray(C.prototype))) C = undefined;
1366
- else if (isObject$3(C)) {
1367
- C = C[SPECIES$3];
1368
- if (C === null) C = undefined;
1369
- }
1370
- } return C === undefined ? $Array : C;
1371
- };
1372
-
1373
- var arraySpeciesConstructor = arraySpeciesConstructor$1;
1374
-
1375
- // `ArraySpeciesCreate` abstract operation
1376
- // https://tc39.es/ecma262/#sec-arrayspeciescreate
1377
- var arraySpeciesCreate$1 = function (originalArray, length) {
1378
- return new (arraySpeciesConstructor(originalArray))(length === 0 ? 0 : length);
1379
- };
1380
-
1381
- var $$6 = _export;
1382
- var flattenIntoArray = flattenIntoArray_1;
1383
- var aCallable$6 = aCallable$9;
1384
- var toObject = toObject$3;
1385
- var lengthOfArrayLike$1 = lengthOfArrayLike$4;
1386
- var arraySpeciesCreate = arraySpeciesCreate$1;
1387
-
1388
- // `Array.prototype.flatMap` method
1389
- // https://tc39.es/ecma262/#sec-array.prototype.flatmap
1390
- $$6({ target: 'Array', proto: true }, {
1391
- flatMap: function flatMap(callbackfn /* , thisArg */) {
1392
- var O = toObject(this);
1393
- var sourceLen = lengthOfArrayLike$1(O);
1394
- var A;
1395
- aCallable$6(callbackfn);
1396
- A = arraySpeciesCreate(O, 0);
1397
- A.length = flattenIntoArray(A, O, O, sourceLen, 0, 1, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
1398
- return A;
1399
- }
1400
- });
1401
-
1402
- var objectDefineProperties = {};
1403
-
1404
- var DESCRIPTORS$2 = descriptors;
1405
- var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
1406
- var definePropertyModule = objectDefineProperty;
1407
- var anObject$7 = anObject$c;
1408
- var toIndexedObject = toIndexedObject$4;
1409
- var objectKeys = objectKeys$2;
1410
-
1411
- // `Object.defineProperties` method
1412
- // https://tc39.es/ecma262/#sec-object.defineproperties
1413
- // eslint-disable-next-line es/no-object-defineproperties -- safe
1414
- objectDefineProperties.f = DESCRIPTORS$2 && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
1415
- anObject$7(O);
1416
- var props = toIndexedObject(Properties);
1417
- var keys = objectKeys(Properties);
1418
- var length = keys.length;
1419
- var index = 0;
1420
- var key;
1421
- while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);
1422
- return O;
1423
- };
1424
-
1425
- var getBuiltIn$3 = getBuiltIn$7;
1426
-
1427
- var html$2 = getBuiltIn$3('document', 'documentElement');
1428
-
1429
- /* global ActiveXObject -- old IE, WSH */
1430
- var anObject$6 = anObject$c;
1431
- var definePropertiesModule = objectDefineProperties;
1432
- var enumBugKeys = enumBugKeys$3;
1433
- var hiddenKeys = hiddenKeys$4;
1434
- var html$1 = html$2;
1435
- var documentCreateElement = documentCreateElement$1;
1436
- var sharedKey = sharedKey$2;
1437
-
1438
- var GT = '>';
1439
- var LT = '<';
1440
- var PROTOTYPE = 'prototype';
1441
- var SCRIPT = 'script';
1442
- var IE_PROTO = sharedKey('IE_PROTO');
2033
+ }) ? isConstructorLegacy : isConstructorModern;
1443
2034
 
1444
- var EmptyConstructor = function () { /* empty */ };
2035
+ var isArray = isArray$3;
2036
+ var isConstructor$1 = isConstructor$2;
2037
+ var isObject$6 = isObject$d;
2038
+ var wellKnownSymbol$6 = wellKnownSymbol$f;
1445
2039
 
1446
- var scriptTag = function (content) {
1447
- return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
1448
- };
2040
+ var SPECIES$3 = wellKnownSymbol$6('species');
2041
+ var $Array = Array;
1449
2042
 
1450
- // Create object with fake `null` prototype: use ActiveX Object with cleared prototype
1451
- var NullProtoObjectViaActiveX = function (activeXDocument) {
1452
- activeXDocument.write(scriptTag(''));
1453
- activeXDocument.close();
1454
- var temp = activeXDocument.parentWindow.Object;
1455
- activeXDocument = null; // avoid memory leak
1456
- return temp;
2043
+ // a part of `ArraySpeciesCreate` abstract operation
2044
+ // https://tc39.es/ecma262/#sec-arrayspeciescreate
2045
+ var arraySpeciesConstructor$1 = function (originalArray) {
2046
+ var C;
2047
+ if (isArray(originalArray)) {
2048
+ C = originalArray.constructor;
2049
+ // cross-realm fallback
2050
+ if (isConstructor$1(C) && (C === $Array || isArray(C.prototype))) C = undefined;
2051
+ else if (isObject$6(C)) {
2052
+ C = C[SPECIES$3];
2053
+ if (C === null) C = undefined;
2054
+ }
2055
+ } return C === undefined ? $Array : C;
1457
2056
  };
1458
2057
 
1459
- // Create object with fake `null` prototype: use iframe Object with cleared prototype
1460
- var NullProtoObjectViaIFrame = function () {
1461
- // Thrash, waste and sodomy: IE GC bug
1462
- var iframe = documentCreateElement('iframe');
1463
- var JS = 'java' + SCRIPT + ':';
1464
- var iframeDocument;
1465
- iframe.style.display = 'none';
1466
- html$1.appendChild(iframe);
1467
- // https://github.com/zloirock/core-js/issues/475
1468
- iframe.src = String(JS);
1469
- iframeDocument = iframe.contentWindow.document;
1470
- iframeDocument.open();
1471
- iframeDocument.write(scriptTag('document.F=Object'));
1472
- iframeDocument.close();
1473
- return iframeDocument.F;
1474
- };
2058
+ var arraySpeciesConstructor = arraySpeciesConstructor$1;
1475
2059
 
1476
- // Check for document.domain and active x support
1477
- // No need to use active x approach when document.domain is not set
1478
- // see https://github.com/es-shims/es5-shim/issues/150
1479
- // variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
1480
- // avoid IE GC bug
1481
- var activeXDocument;
1482
- var NullProtoObject = function () {
1483
- try {
1484
- activeXDocument = new ActiveXObject('htmlfile');
1485
- } catch (error) { /* ignore */ }
1486
- NullProtoObject = typeof document != 'undefined'
1487
- ? document.domain && activeXDocument
1488
- ? NullProtoObjectViaActiveX(activeXDocument) // old IE
1489
- : NullProtoObjectViaIFrame()
1490
- : NullProtoObjectViaActiveX(activeXDocument); // WSH
1491
- var length = enumBugKeys.length;
1492
- while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
1493
- return NullProtoObject();
2060
+ // `ArraySpeciesCreate` abstract operation
2061
+ // https://tc39.es/ecma262/#sec-arrayspeciescreate
2062
+ var arraySpeciesCreate$1 = function (originalArray, length) {
2063
+ return new (arraySpeciesConstructor(originalArray))(length === 0 ? 0 : length);
1494
2064
  };
1495
2065
 
1496
- hiddenKeys[IE_PROTO] = true;
2066
+ var $$8 = _export;
2067
+ var flattenIntoArray = flattenIntoArray_1;
2068
+ var aCallable$6 = aCallable$d;
2069
+ var toObject = toObject$5;
2070
+ var lengthOfArrayLike = lengthOfArrayLike$5;
2071
+ var arraySpeciesCreate = arraySpeciesCreate$1;
1497
2072
 
1498
- // `Object.create` method
1499
- // https://tc39.es/ecma262/#sec-object.create
1500
- // eslint-disable-next-line es/no-object-create -- safe
1501
- var objectCreate = Object.create || function create(O, Properties) {
1502
- var result;
1503
- if (O !== null) {
1504
- EmptyConstructor[PROTOTYPE] = anObject$6(O);
1505
- result = new EmptyConstructor();
1506
- EmptyConstructor[PROTOTYPE] = null;
1507
- // add "__proto__" for Object.getPrototypeOf polyfill
1508
- result[IE_PROTO] = O;
1509
- } else result = NullProtoObject();
1510
- return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
1511
- };
2073
+ // `Array.prototype.flatMap` method
2074
+ // https://tc39.es/ecma262/#sec-array.prototype.flatmap
2075
+ $$8({ target: 'Array', proto: true }, {
2076
+ flatMap: function flatMap(callbackfn /* , thisArg */) {
2077
+ var O = toObject(this);
2078
+ var sourceLen = lengthOfArrayLike(O);
2079
+ var A;
2080
+ aCallable$6(callbackfn);
2081
+ A = arraySpeciesCreate(O, 0);
2082
+ A.length = flattenIntoArray(A, O, O, sourceLen, 0, 1, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
2083
+ return A;
2084
+ }
2085
+ });
1512
2086
 
1513
- var wellKnownSymbol$7 = wellKnownSymbol$c;
2087
+ var wellKnownSymbol$5 = wellKnownSymbol$f;
1514
2088
  var create = objectCreate;
1515
2089
  var defineProperty$2 = objectDefineProperty.f;
1516
2090
 
1517
- var UNSCOPABLES = wellKnownSymbol$7('unscopables');
1518
- var ArrayPrototype$1 = Array.prototype;
2091
+ var UNSCOPABLES = wellKnownSymbol$5('unscopables');
2092
+ var ArrayPrototype = Array.prototype;
1519
2093
 
1520
2094
  // Array.prototype[@@unscopables]
1521
2095
  // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
1522
- if (ArrayPrototype$1[UNSCOPABLES] === undefined) {
1523
- defineProperty$2(ArrayPrototype$1, UNSCOPABLES, {
2096
+ if (ArrayPrototype[UNSCOPABLES] === undefined) {
2097
+ defineProperty$2(ArrayPrototype, UNSCOPABLES, {
1524
2098
  configurable: true,
1525
2099
  value: create(null)
1526
2100
  });
@@ -1528,7 +2102,7 @@ if (ArrayPrototype$1[UNSCOPABLES] === undefined) {
1528
2102
 
1529
2103
  // add a key to Array.prototype[@@unscopables]
1530
2104
  var addToUnscopables$1 = function (key) {
1531
- ArrayPrototype$1[UNSCOPABLES][key] = true;
2105
+ ArrayPrototype[UNSCOPABLES][key] = true;
1532
2106
  };
1533
2107
 
1534
2108
  // this method was added to unscopables after implementation
@@ -1538,6 +2112,62 @@ var addToUnscopables = addToUnscopables$1;
1538
2112
  // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
1539
2113
  addToUnscopables('flatMap');
1540
2114
 
2115
+ var call$5 = functionCall;
2116
+ var anObject$3 = anObject$i;
2117
+ var getIteratorDirect$1 = getIteratorDirect$5;
2118
+ var getIteratorMethod = getIteratorMethod$3;
2119
+
2120
+ var getIteratorFlattenable$1 = function (obj, stringHandling) {
2121
+ if (!stringHandling || typeof obj !== 'string') anObject$3(obj);
2122
+ var method = getIteratorMethod(obj);
2123
+ return getIteratorDirect$1(anObject$3(method !== undefined ? call$5(method, obj) : obj));
2124
+ };
2125
+
2126
+ var $$7 = _export;
2127
+ var call$4 = functionCall;
2128
+ var aCallable$5 = aCallable$d;
2129
+ var anObject$2 = anObject$i;
2130
+ var getIteratorDirect = getIteratorDirect$5;
2131
+ var getIteratorFlattenable = getIteratorFlattenable$1;
2132
+ var createIteratorProxy = iteratorCreateProxy;
2133
+ var iteratorClose = iteratorClose$4;
2134
+ var IS_PURE = isPure;
2135
+
2136
+ var IteratorProxy = createIteratorProxy(function () {
2137
+ var iterator = this.iterator;
2138
+ var mapper = this.mapper;
2139
+ var result, inner;
2140
+
2141
+ while (true) {
2142
+ if (inner = this.inner) try {
2143
+ result = anObject$2(call$4(inner.next, inner.iterator));
2144
+ if (!result.done) return result.value;
2145
+ this.inner = null;
2146
+ } catch (error) { iteratorClose(iterator, 'throw', error); }
2147
+
2148
+ result = anObject$2(call$4(this.next, iterator));
2149
+
2150
+ if (this.done = !!result.done) return;
2151
+
2152
+ try {
2153
+ this.inner = getIteratorFlattenable(mapper(result.value, this.counter++), false);
2154
+ } catch (error) { iteratorClose(iterator, 'throw', error); }
2155
+ }
2156
+ });
2157
+
2158
+ // `Iterator.prototype.flatMap` method
2159
+ // https://github.com/tc39/proposal-iterator-helpers
2160
+ $$7({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, {
2161
+ flatMap: function flatMap(mapper) {
2162
+ anObject$2(this);
2163
+ aCallable$5(mapper);
2164
+ return new IteratorProxy(getIteratorDirect(this), {
2165
+ mapper: mapper,
2166
+ inner: null
2167
+ });
2168
+ }
2169
+ });
2170
+
1541
2171
  /**
1542
2172
  * Candidates module name
1543
2173
  */
@@ -1592,7 +2222,6 @@ function zohoRecruitSearchRecordsCriteriaStringForTree(tree) {
1592
2222
  function mergeStringValues(values, type) {
1593
2223
  return values.length > 1 ? `(${values.join(type)})` : values[0]; // wrap in and values
1594
2224
  }
1595
-
1596
2225
  function mergeValues(values, type) {
1597
2226
  const allStrings = util.filterMaybeArrayValues(values.map(convertToString)).flatMap(util.asArray);
1598
2227
  return mergeStringValues(allStrings, type);
@@ -1625,40 +2254,41 @@ function zohoRecruitSearchRecordsCriteriaEntryToCriteriaString(entry) {
1625
2254
  return `(${entry.field}:${entry.filter}:${escapedValue})`;
1626
2255
  }
1627
2256
 
1628
- var global$7 = global$i;
1629
- var classof$1 = classofRaw$2;
2257
+ var global$8 = global$j;
2258
+ var classof = classofRaw$2;
1630
2259
 
1631
- var engineIsNode = classof$1(global$7.process) === 'process';
2260
+ var engineIsNode = classof(global$8.process) === 'process';
1632
2261
 
1633
- var uncurryThis$1 = functionUncurryThis;
1634
- var aCallable$5 = aCallable$9;
2262
+ var uncurryThis$2 = functionUncurryThis;
2263
+ var aCallable$4 = aCallable$d;
1635
2264
 
1636
2265
  var functionUncurryThisAccessor = function (object, key, method) {
1637
2266
  try {
1638
2267
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
1639
- return uncurryThis$1(aCallable$5(Object.getOwnPropertyDescriptor(object, key)[method]));
2268
+ return uncurryThis$2(aCallable$4(Object.getOwnPropertyDescriptor(object, key)[method]));
1640
2269
  } catch (error) { /* empty */ }
1641
2270
  };
1642
2271
 
1643
- var isObject$2 = isObject$9;
2272
+ var isObject$5 = isObject$d;
1644
2273
 
1645
2274
  var isPossiblePrototype$1 = function (argument) {
1646
- return isObject$2(argument) || argument === null;
2275
+ return isObject$5(argument) || argument === null;
1647
2276
  };
1648
2277
 
1649
2278
  var isPossiblePrototype = isPossiblePrototype$1;
1650
2279
 
1651
2280
  var $String = String;
1652
- var $TypeError$6 = TypeError;
2281
+ var $TypeError$3 = TypeError;
1653
2282
 
1654
2283
  var aPossiblePrototype$1 = function (argument) {
1655
2284
  if (isPossiblePrototype(argument)) return argument;
1656
- throw new $TypeError$6("Can't set " + $String(argument) + ' as a prototype');
2285
+ throw new $TypeError$3("Can't set " + $String(argument) + ' as a prototype');
1657
2286
  };
1658
2287
 
1659
2288
  /* eslint-disable no-proto -- safe */
1660
2289
  var uncurryThisAccessor = functionUncurryThisAccessor;
1661
- var anObject$5 = anObject$c;
2290
+ var isObject$4 = isObject$d;
2291
+ var requireObjectCoercible = requireObjectCoercible$3;
1662
2292
  var aPossiblePrototype = aPossiblePrototype$1;
1663
2293
 
1664
2294
  // `Object.setPrototypeOf` method
@@ -1675,8 +2305,9 @@ var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? functio
1675
2305
  CORRECT_SETTER = test instanceof Array;
1676
2306
  } catch (error) { /* empty */ }
1677
2307
  return function setPrototypeOf(O, proto) {
1678
- anObject$5(O);
2308
+ requireObjectCoercible(O);
1679
2309
  aPossiblePrototype(proto);
2310
+ if (!isObject$4(O)) return O;
1680
2311
  if (CORRECT_SETTER) setter(O, proto);
1681
2312
  else O.__proto__ = proto;
1682
2313
  return O;
@@ -1684,38 +2315,29 @@ var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? functio
1684
2315
  }() : undefined);
1685
2316
 
1686
2317
  var defineProperty$1 = objectDefineProperty.f;
1687
- var hasOwn$1 = hasOwnProperty_1;
1688
- var wellKnownSymbol$6 = wellKnownSymbol$c;
2318
+ var hasOwn$2 = hasOwnProperty_1;
2319
+ var wellKnownSymbol$4 = wellKnownSymbol$f;
1689
2320
 
1690
- var TO_STRING_TAG = wellKnownSymbol$6('toStringTag');
2321
+ var TO_STRING_TAG = wellKnownSymbol$4('toStringTag');
1691
2322
 
1692
2323
  var setToStringTag$1 = function (target, TAG, STATIC) {
1693
2324
  if (target && !STATIC) target = target.prototype;
1694
- if (target && !hasOwn$1(target, TO_STRING_TAG)) {
2325
+ if (target && !hasOwn$2(target, TO_STRING_TAG)) {
1695
2326
  defineProperty$1(target, TO_STRING_TAG, { configurable: true, value: TAG });
1696
2327
  }
1697
2328
  };
1698
2329
 
1699
- var makeBuiltIn = makeBuiltIn$3.exports;
1700
- var defineProperty = objectDefineProperty;
1701
-
1702
- var defineBuiltInAccessor$1 = function (target, name, descriptor) {
1703
- if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });
1704
- if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });
1705
- return defineProperty.f(target, name, descriptor);
1706
- };
1707
-
1708
- var getBuiltIn$2 = getBuiltIn$7;
1709
- var defineBuiltInAccessor = defineBuiltInAccessor$1;
1710
- var wellKnownSymbol$5 = wellKnownSymbol$c;
1711
- var DESCRIPTORS$1 = descriptors;
2330
+ var getBuiltIn$3 = getBuiltIn$8;
2331
+ var defineBuiltInAccessor = defineBuiltInAccessor$2;
2332
+ var wellKnownSymbol$3 = wellKnownSymbol$f;
2333
+ var DESCRIPTORS$2 = descriptors;
1712
2334
 
1713
- var SPECIES$2 = wellKnownSymbol$5('species');
2335
+ var SPECIES$2 = wellKnownSymbol$3('species');
1714
2336
 
1715
2337
  var setSpecies$1 = function (CONSTRUCTOR_NAME) {
1716
- var Constructor = getBuiltIn$2(CONSTRUCTOR_NAME);
2338
+ var Constructor = getBuiltIn$3(CONSTRUCTOR_NAME);
1717
2339
 
1718
- if (DESCRIPTORS$1 && Constructor && !Constructor[SPECIES$2]) {
2340
+ if (DESCRIPTORS$2 && Constructor && !Constructor[SPECIES$2]) {
1719
2341
  defineBuiltInAccessor(Constructor, SPECIES$2, {
1720
2342
  configurable: true,
1721
2343
  get: function () { return this; }
@@ -1723,60 +2345,51 @@ var setSpecies$1 = function (CONSTRUCTOR_NAME) {
1723
2345
  }
1724
2346
  };
1725
2347
 
1726
- var isPrototypeOf$1 = objectIsPrototypeOf;
1727
-
1728
- var $TypeError$5 = TypeError;
1729
-
1730
- var anInstance$1 = function (it, Prototype) {
1731
- if (isPrototypeOf$1(Prototype, it)) return it;
1732
- throw new $TypeError$5('Incorrect invocation');
1733
- };
1734
-
1735
2348
  var isConstructor = isConstructor$2;
1736
- var tryToString$2 = tryToString$4;
2349
+ var tryToString = tryToString$4;
1737
2350
 
1738
- var $TypeError$4 = TypeError;
2351
+ var $TypeError$2 = TypeError;
1739
2352
 
1740
2353
  // `Assert: IsConstructor(argument) is true`
1741
2354
  var aConstructor$1 = function (argument) {
1742
2355
  if (isConstructor(argument)) return argument;
1743
- throw new $TypeError$4(tryToString$2(argument) + ' is not a constructor');
2356
+ throw new $TypeError$2(tryToString(argument) + ' is not a constructor');
1744
2357
  };
1745
2358
 
1746
- var anObject$4 = anObject$c;
2359
+ var anObject$1 = anObject$i;
1747
2360
  var aConstructor = aConstructor$1;
1748
- var isNullOrUndefined$1 = isNullOrUndefined$4;
1749
- var wellKnownSymbol$4 = wellKnownSymbol$c;
2361
+ var isNullOrUndefined = isNullOrUndefined$4;
2362
+ var wellKnownSymbol$2 = wellKnownSymbol$f;
1750
2363
 
1751
- var SPECIES$1 = wellKnownSymbol$4('species');
2364
+ var SPECIES$1 = wellKnownSymbol$2('species');
1752
2365
 
1753
2366
  // `SpeciesConstructor` abstract operation
1754
2367
  // https://tc39.es/ecma262/#sec-speciesconstructor
1755
2368
  var speciesConstructor$1 = function (O, defaultConstructor) {
1756
- var C = anObject$4(O).constructor;
2369
+ var C = anObject$1(O).constructor;
1757
2370
  var S;
1758
- return C === undefined || isNullOrUndefined$1(S = anObject$4(C)[SPECIES$1]) ? defaultConstructor : aConstructor(S);
2371
+ return C === undefined || isNullOrUndefined(S = anObject$1(C)[SPECIES$1]) ? defaultConstructor : aConstructor(S);
1759
2372
  };
1760
2373
 
1761
2374
  var NATIVE_BIND = functionBindNative;
1762
2375
 
1763
2376
  var FunctionPrototype = Function.prototype;
1764
- var apply$1 = FunctionPrototype.apply;
1765
- var call$6 = FunctionPrototype.call;
2377
+ var apply$2 = FunctionPrototype.apply;
2378
+ var call$3 = FunctionPrototype.call;
1766
2379
 
1767
2380
  // eslint-disable-next-line es/no-reflect -- safe
1768
- var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call$6.bind(apply$1) : function () {
1769
- return call$6.apply(apply$1, arguments);
2381
+ var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call$3.bind(apply$2) : function () {
2382
+ return call$3.apply(apply$2, arguments);
1770
2383
  });
1771
2384
 
1772
- var uncurryThis = functionUncurryThis;
2385
+ var uncurryThis$1 = functionUncurryThis;
1773
2386
 
1774
- var arraySlice$1 = uncurryThis([].slice);
2387
+ var arraySlice$1 = uncurryThis$1([].slice);
1775
2388
 
1776
- var $TypeError$3 = TypeError;
2389
+ var $TypeError$1 = TypeError;
1777
2390
 
1778
2391
  var validateArgumentsLength$1 = function (passed, required) {
1779
- if (passed < required) throw new $TypeError$3('Not enough arguments');
2392
+ if (passed < required) throw new $TypeError$1('Not enough arguments');
1780
2393
  return passed;
1781
2394
  };
1782
2395
 
@@ -1785,12 +2398,12 @@ var userAgent$2 = engineUserAgent;
1785
2398
  // eslint-disable-next-line redos/no-vulnerable -- safe
1786
2399
  var engineIsIos = /(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent$2);
1787
2400
 
1788
- var global$6 = global$i;
1789
- var apply = functionApply;
1790
- var bind$3 = functionBindContext;
1791
- var isCallable$3 = isCallable$g;
1792
- var hasOwn = hasOwnProperty_1;
1793
- var fails = fails$c;
2401
+ var global$7 = global$j;
2402
+ var apply$1 = functionApply;
2403
+ var bind$2 = functionBindContext;
2404
+ var isCallable$4 = isCallable$k;
2405
+ var hasOwn$1 = hasOwnProperty_1;
2406
+ var fails$1 = fails$h;
1794
2407
  var html = html$2;
1795
2408
  var arraySlice = arraySlice$1;
1796
2409
  var createElement = documentCreateElement$1;
@@ -1798,25 +2411,25 @@ var validateArgumentsLength = validateArgumentsLength$1;
1798
2411
  var IS_IOS$1 = engineIsIos;
1799
2412
  var IS_NODE$3 = engineIsNode;
1800
2413
 
1801
- var set = global$6.setImmediate;
1802
- var clear = global$6.clearImmediate;
1803
- var process$2 = global$6.process;
1804
- var Dispatch = global$6.Dispatch;
1805
- var Function$1 = global$6.Function;
1806
- var MessageChannel = global$6.MessageChannel;
1807
- var String$1 = global$6.String;
2414
+ var set = global$7.setImmediate;
2415
+ var clear = global$7.clearImmediate;
2416
+ var process$2 = global$7.process;
2417
+ var Dispatch = global$7.Dispatch;
2418
+ var Function$1 = global$7.Function;
2419
+ var MessageChannel = global$7.MessageChannel;
2420
+ var String$1 = global$7.String;
1808
2421
  var counter = 0;
1809
2422
  var queue$2 = {};
1810
2423
  var ONREADYSTATECHANGE = 'onreadystatechange';
1811
2424
  var $location, defer, channel, port;
1812
2425
 
1813
- fails(function () {
2426
+ fails$1(function () {
1814
2427
  // Deno throws a ReferenceError on `location` access without `--location` flag
1815
- $location = global$6.location;
2428
+ $location = global$7.location;
1816
2429
  });
1817
2430
 
1818
2431
  var run = function (id) {
1819
- if (hasOwn(queue$2, id)) {
2432
+ if (hasOwn$1(queue$2, id)) {
1820
2433
  var fn = queue$2[id];
1821
2434
  delete queue$2[id];
1822
2435
  fn();
@@ -1835,17 +2448,17 @@ var eventListener = function (event) {
1835
2448
 
1836
2449
  var globalPostMessageDefer = function (id) {
1837
2450
  // old engines have not location.origin
1838
- global$6.postMessage(String$1(id), $location.protocol + '//' + $location.host);
2451
+ global$7.postMessage(String$1(id), $location.protocol + '//' + $location.host);
1839
2452
  };
1840
2453
 
1841
2454
  // Node.js 0.9+ & IE10+ has setImmediate, otherwise:
1842
2455
  if (!set || !clear) {
1843
2456
  set = function setImmediate(handler) {
1844
2457
  validateArgumentsLength(arguments.length, 1);
1845
- var fn = isCallable$3(handler) ? handler : Function$1(handler);
2458
+ var fn = isCallable$4(handler) ? handler : Function$1(handler);
1846
2459
  var args = arraySlice(arguments, 1);
1847
2460
  queue$2[++counter] = function () {
1848
- apply(fn, undefined, args);
2461
+ apply$1(fn, undefined, args);
1849
2462
  };
1850
2463
  defer(counter);
1851
2464
  return counter;
@@ -1869,18 +2482,18 @@ if (!set || !clear) {
1869
2482
  channel = new MessageChannel();
1870
2483
  port = channel.port2;
1871
2484
  channel.port1.onmessage = eventListener;
1872
- defer = bind$3(port.postMessage, port);
2485
+ defer = bind$2(port.postMessage, port);
1873
2486
  // Browsers with postMessage, skip WebWorkers
1874
2487
  // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
1875
2488
  } else if (
1876
- global$6.addEventListener &&
1877
- isCallable$3(global$6.postMessage) &&
1878
- !global$6.importScripts &&
2489
+ global$7.addEventListener &&
2490
+ isCallable$4(global$7.postMessage) &&
2491
+ !global$7.importScripts &&
1879
2492
  $location && $location.protocol !== 'file:' &&
1880
- !fails(globalPostMessageDefer)
2493
+ !fails$1(globalPostMessageDefer)
1881
2494
  ) {
1882
2495
  defer = globalPostMessageDefer;
1883
- global$6.addEventListener('message', eventListener, false);
2496
+ global$7.addEventListener('message', eventListener, false);
1884
2497
  // IE8-
1885
2498
  } else if (ONREADYSTATECHANGE in createElement('script')) {
1886
2499
  defer = function (id) {
@@ -1902,16 +2515,16 @@ var task$1 = {
1902
2515
  clear: clear
1903
2516
  };
1904
2517
 
1905
- var global$5 = global$i;
1906
- var DESCRIPTORS = descriptors;
2518
+ var global$6 = global$j;
2519
+ var DESCRIPTORS$1 = descriptors;
1907
2520
 
1908
2521
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
1909
2522
  var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
1910
2523
 
1911
2524
  // Avoid NodeJS experimental warning
1912
2525
  var safeGetBuiltIn$1 = function (name) {
1913
- if (!DESCRIPTORS) return global$5[name];
1914
- var descriptor = getOwnPropertyDescriptor(global$5, name);
2526
+ if (!DESCRIPTORS$1) return global$6[name];
2527
+ var descriptor = getOwnPropertyDescriptor(global$6, name);
1915
2528
  return descriptor && descriptor.value;
1916
2529
  };
1917
2530
 
@@ -1948,9 +2561,9 @@ var userAgent = engineUserAgent;
1948
2561
 
1949
2562
  var engineIsWebosWebkit = /web0s(?!.*chrome)/i.test(userAgent);
1950
2563
 
1951
- var global$4 = global$i;
2564
+ var global$5 = global$j;
1952
2565
  var safeGetBuiltIn = safeGetBuiltIn$1;
1953
- var bind$2 = functionBindContext;
2566
+ var bind$1 = functionBindContext;
1954
2567
  var macrotask = task$1.set;
1955
2568
  var Queue$1 = queue$1;
1956
2569
  var IS_IOS = engineIsIos;
@@ -1958,10 +2571,10 @@ var IS_IOS_PEBBLE = engineIsIosPebble;
1958
2571
  var IS_WEBOS_WEBKIT = engineIsWebosWebkit;
1959
2572
  var IS_NODE$2 = engineIsNode;
1960
2573
 
1961
- var MutationObserver = global$4.MutationObserver || global$4.WebKitMutationObserver;
1962
- var document$2 = global$4.document;
1963
- var process$1 = global$4.process;
1964
- var Promise$1 = global$4.Promise;
2574
+ var MutationObserver = global$5.MutationObserver || global$5.WebKitMutationObserver;
2575
+ var document$2 = global$5.document;
2576
+ var process$1 = global$5.process;
2577
+ var Promise$1 = global$5.Promise;
1965
2578
  var microtask$1 = safeGetBuiltIn('queueMicrotask');
1966
2579
  var notify$1, toggle, node, promise, then;
1967
2580
 
@@ -1996,7 +2609,7 @@ if (!microtask$1) {
1996
2609
  promise = Promise$1.resolve(undefined);
1997
2610
  // workaround of WebKit ~ iOS Safari 10.1 bug
1998
2611
  promise.constructor = Promise$1;
1999
- then = bind$2(promise.then, promise);
2612
+ then = bind$1(promise.then, promise);
2000
2613
  notify$1 = function () {
2001
2614
  then(flush);
2002
2615
  };
@@ -2013,7 +2626,7 @@ if (!microtask$1) {
2013
2626
  // - setTimeout
2014
2627
  } else {
2015
2628
  // `webpack` dev server bug on IE global methods - use bind(fn, global)
2016
- macrotask = bind$2(macrotask, global$4);
2629
+ macrotask = bind$1(macrotask, global$5);
2017
2630
  notify$1 = function () {
2018
2631
  macrotask(flush);
2019
2632
  };
@@ -2042,9 +2655,9 @@ var perform$3 = function (exec) {
2042
2655
  }
2043
2656
  };
2044
2657
 
2045
- var global$3 = global$i;
2658
+ var global$4 = global$j;
2046
2659
 
2047
- var promiseNativeConstructor = global$3.Promise;
2660
+ var promiseNativeConstructor = global$4.Promise;
2048
2661
 
2049
2662
  /* global Deno -- Deno case */
2050
2663
  var engineIsDeno = typeof Deno == 'object' && Deno && typeof Deno.version == 'object';
@@ -2056,20 +2669,20 @@ var engineIsBrowser = !IS_DENO$1 && !IS_NODE$1
2056
2669
  && typeof window == 'object'
2057
2670
  && typeof document == 'object';
2058
2671
 
2059
- var global$2 = global$i;
2672
+ var global$3 = global$j;
2060
2673
  var NativePromiseConstructor$3 = promiseNativeConstructor;
2061
- var isCallable$2 = isCallable$g;
2674
+ var isCallable$3 = isCallable$k;
2062
2675
  var isForced = isForced_1;
2063
2676
  var inspectSource = inspectSource$3;
2064
- var wellKnownSymbol$3 = wellKnownSymbol$c;
2677
+ var wellKnownSymbol$1 = wellKnownSymbol$f;
2065
2678
  var IS_BROWSER = engineIsBrowser;
2066
2679
  var IS_DENO = engineIsDeno;
2067
2680
  var V8_VERSION = engineV8Version;
2068
2681
 
2069
2682
  NativePromiseConstructor$3 && NativePromiseConstructor$3.prototype;
2070
- var SPECIES = wellKnownSymbol$3('species');
2683
+ var SPECIES = wellKnownSymbol$1('species');
2071
2684
  var SUBCLASSING = false;
2072
- var NATIVE_PROMISE_REJECTION_EVENT$1 = isCallable$2(global$2.PromiseRejectionEvent);
2685
+ var NATIVE_PROMISE_REJECTION_EVENT$1 = isCallable$3(global$3.PromiseRejectionEvent);
2073
2686
 
2074
2687
  var FORCED_PROMISE_CONSTRUCTOR$5 = isForced('Promise', function () {
2075
2688
  var PROMISE_CONSTRUCTOR_SOURCE = inspectSource(NativePromiseConstructor$3);
@@ -2103,19 +2716,19 @@ var promiseConstructorDetection = {
2103
2716
 
2104
2717
  var newPromiseCapability$2 = {};
2105
2718
 
2106
- var aCallable$4 = aCallable$9;
2719
+ var aCallable$3 = aCallable$d;
2107
2720
 
2108
- var $TypeError$2 = TypeError;
2721
+ var $TypeError = TypeError;
2109
2722
 
2110
2723
  var PromiseCapability = function (C) {
2111
2724
  var resolve, reject;
2112
2725
  this.promise = new C(function ($$resolve, $$reject) {
2113
- if (resolve !== undefined || reject !== undefined) throw new $TypeError$2('Bad Promise constructor');
2726
+ if (resolve !== undefined || reject !== undefined) throw new $TypeError('Bad Promise constructor');
2114
2727
  resolve = $$resolve;
2115
2728
  reject = $$reject;
2116
2729
  });
2117
- this.resolve = aCallable$4(resolve);
2118
- this.reject = aCallable$4(reject);
2730
+ this.resolve = aCallable$3(resolve);
2731
+ this.reject = aCallable$3(reject);
2119
2732
  };
2120
2733
 
2121
2734
  // `NewPromiseCapability` abstract operation
@@ -2124,18 +2737,18 @@ newPromiseCapability$2.f = function (C) {
2124
2737
  return new PromiseCapability(C);
2125
2738
  };
2126
2739
 
2127
- var $$5 = _export;
2740
+ var $$6 = _export;
2128
2741
  var IS_NODE = engineIsNode;
2129
- var global$1 = global$i;
2130
- var call$5 = functionCall;
2131
- var defineBuiltIn$1 = defineBuiltIn$4;
2132
- var setPrototypeOf = objectSetPrototypeOf;
2742
+ var global$2 = global$j;
2743
+ var call$2 = functionCall;
2744
+ var defineBuiltIn$1 = defineBuiltIn$6;
2745
+ var setPrototypeOf$2 = objectSetPrototypeOf;
2133
2746
  var setToStringTag = setToStringTag$1;
2134
2747
  var setSpecies = setSpecies$1;
2135
- var aCallable$3 = aCallable$9;
2136
- var isCallable$1 = isCallable$g;
2137
- var isObject$1 = isObject$9;
2138
- var anInstance = anInstance$1;
2748
+ var aCallable$2 = aCallable$d;
2749
+ var isCallable$2 = isCallable$k;
2750
+ var isObject$3 = isObject$d;
2751
+ var anInstance = anInstance$2;
2139
2752
  var speciesConstructor = speciesConstructor$1;
2140
2753
  var task = task$1.set;
2141
2754
  var microtask = microtask_1;
@@ -2156,13 +2769,13 @@ var setInternalState = InternalStateModule.set;
2156
2769
  var NativePromisePrototype$1 = NativePromiseConstructor$2 && NativePromiseConstructor$2.prototype;
2157
2770
  var PromiseConstructor = NativePromiseConstructor$2;
2158
2771
  var PromisePrototype = NativePromisePrototype$1;
2159
- var TypeError$1 = global$1.TypeError;
2160
- var document$1 = global$1.document;
2161
- var process = global$1.process;
2772
+ var TypeError$1 = global$2.TypeError;
2773
+ var document$1 = global$2.document;
2774
+ var process = global$2.process;
2162
2775
  var newPromiseCapability$1 = newPromiseCapabilityModule$3.f;
2163
2776
  var newGenericPromiseCapability = newPromiseCapability$1;
2164
2777
 
2165
- var DISPATCH_EVENT = !!(document$1 && document$1.createEvent && global$1.dispatchEvent);
2778
+ var DISPATCH_EVENT = !!(document$1 && document$1.createEvent && global$2.dispatchEvent);
2166
2779
  var UNHANDLED_REJECTION = 'unhandledrejection';
2167
2780
  var REJECTION_HANDLED = 'rejectionhandled';
2168
2781
  var PENDING = 0;
@@ -2176,7 +2789,7 @@ var Internal, OwnPromiseCapability, PromiseWrapper, nativeThen;
2176
2789
  // helpers
2177
2790
  var isThenable = function (it) {
2178
2791
  var then;
2179
- return isObject$1(it) && isCallable$1(then = it.then) ? then : false;
2792
+ return isObject$3(it) && isCallable$2(then = it.then) ? then : false;
2180
2793
  };
2181
2794
 
2182
2795
  var callReaction = function (reaction, state) {
@@ -2205,7 +2818,7 @@ var callReaction = function (reaction, state) {
2205
2818
  if (result === reaction.promise) {
2206
2819
  reject(new TypeError$1('Promise-chain cycle'));
2207
2820
  } else if (then = isThenable(result)) {
2208
- call$5(then, result, resolve, reject);
2821
+ call$2(then, result, resolve, reject);
2209
2822
  } else resolve(result);
2210
2823
  } else reject(value);
2211
2824
  } catch (error) {
@@ -2235,14 +2848,14 @@ var dispatchEvent = function (name, promise, reason) {
2235
2848
  event.promise = promise;
2236
2849
  event.reason = reason;
2237
2850
  event.initEvent(name, false, true);
2238
- global$1.dispatchEvent(event);
2851
+ global$2.dispatchEvent(event);
2239
2852
  } else event = { promise: promise, reason: reason };
2240
- if (!NATIVE_PROMISE_REJECTION_EVENT && (handler = global$1['on' + name])) handler(event);
2853
+ if (!NATIVE_PROMISE_REJECTION_EVENT && (handler = global$2['on' + name])) handler(event);
2241
2854
  else if (name === UNHANDLED_REJECTION) hostReportErrors('Unhandled promise rejection', reason);
2242
2855
  };
2243
2856
 
2244
2857
  var onUnhandled = function (state) {
2245
- call$5(task, global$1, function () {
2858
+ call$2(task, global$2, function () {
2246
2859
  var promise = state.facade;
2247
2860
  var value = state.value;
2248
2861
  var IS_UNHANDLED = isUnhandled(state);
@@ -2265,7 +2878,7 @@ var isUnhandled = function (state) {
2265
2878
  };
2266
2879
 
2267
2880
  var onHandleUnhandled = function (state) {
2268
- call$5(task, global$1, function () {
2881
+ call$2(task, global$2, function () {
2269
2882
  var promise = state.facade;
2270
2883
  if (IS_NODE) {
2271
2884
  process.emit('rejectionHandled', promise);
@@ -2273,7 +2886,7 @@ var onHandleUnhandled = function (state) {
2273
2886
  });
2274
2887
  };
2275
2888
 
2276
- var bind$1 = function (fn, state, unwrap) {
2889
+ var bind = function (fn, state, unwrap) {
2277
2890
  return function (value) {
2278
2891
  fn(state, value, unwrap);
2279
2892
  };
@@ -2299,9 +2912,9 @@ var internalResolve = function (state, value, unwrap) {
2299
2912
  microtask(function () {
2300
2913
  var wrapper = { done: false };
2301
2914
  try {
2302
- call$5(then, value,
2303
- bind$1(internalResolve, wrapper, state),
2304
- bind$1(internalReject, wrapper, state)
2915
+ call$2(then, value,
2916
+ bind(internalResolve, wrapper, state),
2917
+ bind(internalReject, wrapper, state)
2305
2918
  );
2306
2919
  } catch (error) {
2307
2920
  internalReject(wrapper, error, state);
@@ -2322,11 +2935,11 @@ if (FORCED_PROMISE_CONSTRUCTOR$4) {
2322
2935
  // 25.4.3.1 Promise(executor)
2323
2936
  PromiseConstructor = function Promise(executor) {
2324
2937
  anInstance(this, PromisePrototype);
2325
- aCallable$3(executor);
2326
- call$5(Internal, this);
2938
+ aCallable$2(executor);
2939
+ call$2(Internal, this);
2327
2940
  var state = getInternalPromiseState(this);
2328
2941
  try {
2329
- executor(bind$1(internalResolve, state), bind$1(internalReject, state));
2942
+ executor(bind(internalResolve, state), bind(internalReject, state));
2330
2943
  } catch (error) {
2331
2944
  internalReject(state, error);
2332
2945
  }
@@ -2354,8 +2967,8 @@ if (FORCED_PROMISE_CONSTRUCTOR$4) {
2354
2967
  var state = getInternalPromiseState(this);
2355
2968
  var reaction = newPromiseCapability$1(speciesConstructor(this, PromiseConstructor));
2356
2969
  state.parent = true;
2357
- reaction.ok = isCallable$1(onFulfilled) ? onFulfilled : true;
2358
- reaction.fail = isCallable$1(onRejected) && onRejected;
2970
+ reaction.ok = isCallable$2(onFulfilled) ? onFulfilled : true;
2971
+ reaction.fail = isCallable$2(onRejected) && onRejected;
2359
2972
  reaction.domain = IS_NODE ? process.domain : undefined;
2360
2973
  if (state.state === PENDING) state.reactions.add(reaction);
2361
2974
  else microtask(function () {
@@ -2365,187 +2978,53 @@ if (FORCED_PROMISE_CONSTRUCTOR$4) {
2365
2978
  });
2366
2979
 
2367
2980
  OwnPromiseCapability = function () {
2368
- var promise = new Internal();
2369
- var state = getInternalPromiseState(promise);
2370
- this.promise = promise;
2371
- this.resolve = bind$1(internalResolve, state);
2372
- this.reject = bind$1(internalReject, state);
2373
- };
2374
-
2375
- newPromiseCapabilityModule$3.f = newPromiseCapability$1 = function (C) {
2376
- return C === PromiseConstructor || C === PromiseWrapper
2377
- ? new OwnPromiseCapability(C)
2378
- : newGenericPromiseCapability(C);
2379
- };
2380
-
2381
- if (isCallable$1(NativePromiseConstructor$2) && NativePromisePrototype$1 !== Object.prototype) {
2382
- nativeThen = NativePromisePrototype$1.then;
2383
-
2384
- if (!NATIVE_PROMISE_SUBCLASSING) {
2385
- // make `Promise#then` return a polyfilled `Promise` for native promise-based APIs
2386
- defineBuiltIn$1(NativePromisePrototype$1, 'then', function then(onFulfilled, onRejected) {
2387
- var that = this;
2388
- return new PromiseConstructor(function (resolve, reject) {
2389
- call$5(nativeThen, that, resolve, reject);
2390
- }).then(onFulfilled, onRejected);
2391
- // https://github.com/zloirock/core-js/issues/640
2392
- }, { unsafe: true });
2393
- }
2394
-
2395
- // make `.constructor === Promise` work for native promise-based APIs
2396
- try {
2397
- delete NativePromisePrototype$1.constructor;
2398
- } catch (error) { /* empty */ }
2399
-
2400
- // make `instanceof Promise` work for native promise-based APIs
2401
- if (setPrototypeOf) {
2402
- setPrototypeOf(NativePromisePrototype$1, PromisePrototype);
2403
- }
2404
- }
2405
- }
2406
-
2407
- $$5({ global: true, constructor: true, wrap: true, forced: FORCED_PROMISE_CONSTRUCTOR$4 }, {
2408
- Promise: PromiseConstructor
2409
- });
2410
-
2411
- setToStringTag(PromiseConstructor, PROMISE, false);
2412
- setSpecies(PROMISE);
2413
-
2414
- var iterators = {};
2415
-
2416
- var wellKnownSymbol$2 = wellKnownSymbol$c;
2417
- var Iterators$1 = iterators;
2418
-
2419
- var ITERATOR$2 = wellKnownSymbol$2('iterator');
2420
- var ArrayPrototype = Array.prototype;
2421
-
2422
- // check on default Array iterator
2423
- var isArrayIteratorMethod$1 = function (it) {
2424
- return it !== undefined && (Iterators$1.Array === it || ArrayPrototype[ITERATOR$2] === it);
2425
- };
2426
-
2427
- var classof = classof$6;
2428
- var getMethod$1 = getMethod$3;
2429
- var isNullOrUndefined = isNullOrUndefined$4;
2430
- var Iterators = iterators;
2431
- var wellKnownSymbol$1 = wellKnownSymbol$c;
2432
-
2433
- var ITERATOR$1 = wellKnownSymbol$1('iterator');
2434
-
2435
- var getIteratorMethod$2 = function (it) {
2436
- if (!isNullOrUndefined(it)) return getMethod$1(it, ITERATOR$1)
2437
- || getMethod$1(it, '@@iterator')
2438
- || Iterators[classof(it)];
2439
- };
2440
-
2441
- var call$4 = functionCall;
2442
- var aCallable$2 = aCallable$9;
2443
- var anObject$3 = anObject$c;
2444
- var tryToString$1 = tryToString$4;
2445
- var getIteratorMethod$1 = getIteratorMethod$2;
2446
-
2447
- var $TypeError$1 = TypeError;
2448
-
2449
- var getIterator$1 = function (argument, usingIterator) {
2450
- var iteratorMethod = arguments.length < 2 ? getIteratorMethod$1(argument) : usingIterator;
2451
- if (aCallable$2(iteratorMethod)) return anObject$3(call$4(iteratorMethod, argument));
2452
- throw new $TypeError$1(tryToString$1(argument) + ' is not iterable');
2453
- };
2454
-
2455
- var call$3 = functionCall;
2456
- var anObject$2 = anObject$c;
2457
- var getMethod = getMethod$3;
2458
-
2459
- var iteratorClose$1 = function (iterator, kind, value) {
2460
- var innerResult, innerError;
2461
- anObject$2(iterator);
2462
- try {
2463
- innerResult = getMethod(iterator, 'return');
2464
- if (!innerResult) {
2465
- if (kind === 'throw') throw value;
2466
- return value;
2467
- }
2468
- innerResult = call$3(innerResult, iterator);
2469
- } catch (error) {
2470
- innerError = true;
2471
- innerResult = error;
2472
- }
2473
- if (kind === 'throw') throw value;
2474
- if (innerError) throw innerResult;
2475
- anObject$2(innerResult);
2476
- return value;
2477
- };
2478
-
2479
- var bind = functionBindContext;
2480
- var call$2 = functionCall;
2481
- var anObject$1 = anObject$c;
2482
- var tryToString = tryToString$4;
2483
- var isArrayIteratorMethod = isArrayIteratorMethod$1;
2484
- var lengthOfArrayLike = lengthOfArrayLike$4;
2485
- var isPrototypeOf = objectIsPrototypeOf;
2486
- var getIterator = getIterator$1;
2487
- var getIteratorMethod = getIteratorMethod$2;
2488
- var iteratorClose = iteratorClose$1;
2489
-
2490
- var $TypeError = TypeError;
2491
-
2492
- var Result = function (stopped, result) {
2493
- this.stopped = stopped;
2494
- this.result = result;
2495
- };
2496
-
2497
- var ResultPrototype = Result.prototype;
2498
-
2499
- var iterate$2 = function (iterable, unboundFunction, options) {
2500
- var that = options && options.that;
2501
- var AS_ENTRIES = !!(options && options.AS_ENTRIES);
2502
- var IS_RECORD = !!(options && options.IS_RECORD);
2503
- var IS_ITERATOR = !!(options && options.IS_ITERATOR);
2504
- var INTERRUPTED = !!(options && options.INTERRUPTED);
2505
- var fn = bind(unboundFunction, that);
2506
- var iterator, iterFn, index, length, result, next, step;
2507
-
2508
- var stop = function (condition) {
2509
- if (iterator) iteratorClose(iterator, 'normal', condition);
2510
- return new Result(true, condition);
2981
+ var promise = new Internal();
2982
+ var state = getInternalPromiseState(promise);
2983
+ this.promise = promise;
2984
+ this.resolve = bind(internalResolve, state);
2985
+ this.reject = bind(internalReject, state);
2511
2986
  };
2512
2987
 
2513
- var callFn = function (value) {
2514
- if (AS_ENTRIES) {
2515
- anObject$1(value);
2516
- return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
2517
- } return INTERRUPTED ? fn(value, stop) : fn(value);
2988
+ newPromiseCapabilityModule$3.f = newPromiseCapability$1 = function (C) {
2989
+ return C === PromiseConstructor || C === PromiseWrapper
2990
+ ? new OwnPromiseCapability(C)
2991
+ : newGenericPromiseCapability(C);
2518
2992
  };
2519
2993
 
2520
- if (IS_RECORD) {
2521
- iterator = iterable.iterator;
2522
- } else if (IS_ITERATOR) {
2523
- iterator = iterable;
2524
- } else {
2525
- iterFn = getIteratorMethod(iterable);
2526
- if (!iterFn) throw new $TypeError(tryToString(iterable) + ' is not iterable');
2527
- // optimisation for array iterators
2528
- if (isArrayIteratorMethod(iterFn)) {
2529
- for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {
2530
- result = callFn(iterable[index]);
2531
- if (result && isPrototypeOf(ResultPrototype, result)) return result;
2532
- } return new Result(false);
2994
+ if (isCallable$2(NativePromiseConstructor$2) && NativePromisePrototype$1 !== Object.prototype) {
2995
+ nativeThen = NativePromisePrototype$1.then;
2996
+
2997
+ if (!NATIVE_PROMISE_SUBCLASSING) {
2998
+ // make `Promise#then` return a polyfilled `Promise` for native promise-based APIs
2999
+ defineBuiltIn$1(NativePromisePrototype$1, 'then', function then(onFulfilled, onRejected) {
3000
+ var that = this;
3001
+ return new PromiseConstructor(function (resolve, reject) {
3002
+ call$2(nativeThen, that, resolve, reject);
3003
+ }).then(onFulfilled, onRejected);
3004
+ // https://github.com/zloirock/core-js/issues/640
3005
+ }, { unsafe: true });
2533
3006
  }
2534
- iterator = getIterator(iterable, iterFn);
2535
- }
2536
3007
 
2537
- next = IS_RECORD ? iterable.next : iterator.next;
2538
- while (!(step = call$2(next, iterator)).done) {
3008
+ // make `.constructor === Promise` work for native promise-based APIs
2539
3009
  try {
2540
- result = callFn(step.value);
2541
- } catch (error) {
2542
- iteratorClose(iterator, 'throw', error);
3010
+ delete NativePromisePrototype$1.constructor;
3011
+ } catch (error) { /* empty */ }
3012
+
3013
+ // make `instanceof Promise` work for native promise-based APIs
3014
+ if (setPrototypeOf$2) {
3015
+ setPrototypeOf$2(NativePromisePrototype$1, PromisePrototype);
2543
3016
  }
2544
- if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result;
2545
- } return new Result(false);
2546
- };
3017
+ }
3018
+ }
3019
+
3020
+ $$6({ global: true, constructor: true, wrap: true, forced: FORCED_PROMISE_CONSTRUCTOR$4 }, {
3021
+ Promise: PromiseConstructor
3022
+ });
3023
+
3024
+ setToStringTag(PromiseConstructor, PROMISE, false);
3025
+ setSpecies(PROMISE);
2547
3026
 
2548
- var wellKnownSymbol = wellKnownSymbol$c;
3027
+ var wellKnownSymbol = wellKnownSymbol$f;
2549
3028
 
2550
3029
  var ITERATOR = wellKnownSymbol('iterator');
2551
3030
  var SAFE_CLOSING = false;
@@ -2594,17 +3073,17 @@ var promiseStaticsIncorrectIteration = FORCED_PROMISE_CONSTRUCTOR$3 || !checkCor
2594
3073
  NativePromiseConstructor$1.all(iterable).then(undefined, function () { /* empty */ });
2595
3074
  });
2596
3075
 
2597
- var $$4 = _export;
3076
+ var $$5 = _export;
2598
3077
  var call$1 = functionCall;
2599
- var aCallable$1 = aCallable$9;
3078
+ var aCallable$1 = aCallable$d;
2600
3079
  var newPromiseCapabilityModule$2 = newPromiseCapability$2;
2601
3080
  var perform$1 = perform$3;
2602
- var iterate$1 = iterate$2;
3081
+ var iterate$1 = iterate$3;
2603
3082
  var PROMISE_STATICS_INCORRECT_ITERATION$1 = promiseStaticsIncorrectIteration;
2604
3083
 
2605
3084
  // `Promise.all` method
2606
3085
  // https://tc39.es/ecma262/#sec-promise.all
2607
- $$4({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION$1 }, {
3086
+ $$5({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION$1 }, {
2608
3087
  all: function all(iterable) {
2609
3088
  var C = this;
2610
3089
  var capability = newPromiseCapabilityModule$2.f(C);
@@ -2633,42 +3112,42 @@ $$4({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION
2633
3112
  }
2634
3113
  });
2635
3114
 
2636
- var $$3 = _export;
3115
+ var $$4 = _export;
2637
3116
  var FORCED_PROMISE_CONSTRUCTOR$2 = promiseConstructorDetection.CONSTRUCTOR;
2638
3117
  var NativePromiseConstructor = promiseNativeConstructor;
2639
- var getBuiltIn$1 = getBuiltIn$7;
2640
- var isCallable = isCallable$g;
2641
- var defineBuiltIn = defineBuiltIn$4;
3118
+ var getBuiltIn$2 = getBuiltIn$8;
3119
+ var isCallable$1 = isCallable$k;
3120
+ var defineBuiltIn = defineBuiltIn$6;
2642
3121
 
2643
3122
  var NativePromisePrototype = NativePromiseConstructor && NativePromiseConstructor.prototype;
2644
3123
 
2645
3124
  // `Promise.prototype.catch` method
2646
3125
  // https://tc39.es/ecma262/#sec-promise.prototype.catch
2647
- $$3({ target: 'Promise', proto: true, forced: FORCED_PROMISE_CONSTRUCTOR$2, real: true }, {
3126
+ $$4({ target: 'Promise', proto: true, forced: FORCED_PROMISE_CONSTRUCTOR$2, real: true }, {
2648
3127
  'catch': function (onRejected) {
2649
3128
  return this.then(undefined, onRejected);
2650
3129
  }
2651
3130
  });
2652
3131
 
2653
3132
  // makes sure that native promise-based APIs `Promise#catch` properly works with patched `Promise#then`
2654
- if (isCallable(NativePromiseConstructor)) {
2655
- var method = getBuiltIn$1('Promise').prototype['catch'];
3133
+ if (isCallable$1(NativePromiseConstructor)) {
3134
+ var method = getBuiltIn$2('Promise').prototype['catch'];
2656
3135
  if (NativePromisePrototype['catch'] !== method) {
2657
3136
  defineBuiltIn(NativePromisePrototype, 'catch', method, { unsafe: true });
2658
3137
  }
2659
3138
  }
2660
3139
 
2661
- var $$2 = _export;
3140
+ var $$3 = _export;
2662
3141
  var call = functionCall;
2663
- var aCallable = aCallable$9;
3142
+ var aCallable = aCallable$d;
2664
3143
  var newPromiseCapabilityModule$1 = newPromiseCapability$2;
2665
3144
  var perform = perform$3;
2666
- var iterate = iterate$2;
3145
+ var iterate = iterate$3;
2667
3146
  var PROMISE_STATICS_INCORRECT_ITERATION = promiseStaticsIncorrectIteration;
2668
3147
 
2669
3148
  // `Promise.race` method
2670
3149
  // https://tc39.es/ecma262/#sec-promise.race
2671
- $$2({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
3150
+ $$3({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
2672
3151
  race: function race(iterable) {
2673
3152
  var C = this;
2674
3153
  var capability = newPromiseCapabilityModule$1.f(C);
@@ -2684,13 +3163,13 @@ $$2({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION
2684
3163
  }
2685
3164
  });
2686
3165
 
2687
- var $$1 = _export;
3166
+ var $$2 = _export;
2688
3167
  var newPromiseCapabilityModule = newPromiseCapability$2;
2689
3168
  var FORCED_PROMISE_CONSTRUCTOR$1 = promiseConstructorDetection.CONSTRUCTOR;
2690
3169
 
2691
3170
  // `Promise.reject` method
2692
3171
  // https://tc39.es/ecma262/#sec-promise.reject
2693
- $$1({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR$1 }, {
3172
+ $$2({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR$1 }, {
2694
3173
  reject: function reject(r) {
2695
3174
  var capability = newPromiseCapabilityModule.f(this);
2696
3175
  var capabilityReject = capability.reject;
@@ -2699,29 +3178,29 @@ $$1({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR$1 }, {
2699
3178
  }
2700
3179
  });
2701
3180
 
2702
- var anObject = anObject$c;
2703
- var isObject = isObject$9;
3181
+ var anObject = anObject$i;
3182
+ var isObject$2 = isObject$d;
2704
3183
  var newPromiseCapability = newPromiseCapability$2;
2705
3184
 
2706
3185
  var promiseResolve$1 = function (C, x) {
2707
3186
  anObject(C);
2708
- if (isObject(x) && x.constructor === C) return x;
3187
+ if (isObject$2(x) && x.constructor === C) return x;
2709
3188
  var promiseCapability = newPromiseCapability.f(C);
2710
3189
  var resolve = promiseCapability.resolve;
2711
3190
  resolve(x);
2712
3191
  return promiseCapability.promise;
2713
3192
  };
2714
3193
 
2715
- var $ = _export;
2716
- var getBuiltIn = getBuiltIn$7;
3194
+ var $$1 = _export;
3195
+ var getBuiltIn$1 = getBuiltIn$8;
2717
3196
  var FORCED_PROMISE_CONSTRUCTOR = promiseConstructorDetection.CONSTRUCTOR;
2718
3197
  var promiseResolve = promiseResolve$1;
2719
3198
 
2720
- getBuiltIn('Promise');
3199
+ getBuiltIn$1('Promise');
2721
3200
 
2722
3201
  // `Promise.resolve` method
2723
3202
  // https://tc39.es/ecma262/#sec-promise.resolve
2724
- $({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
3203
+ $$1({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
2725
3204
  resolve: function resolve(x) {
2726
3205
  return promiseResolve(this, x);
2727
3206
  }
@@ -2730,46 +3209,6 @@ $({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
2730
3209
  /**
2731
3210
  * A code used in some cases to denote success.
2732
3211
  */
2733
-
2734
- function _await$3(value, then, direct) {
2735
- if (direct) {
2736
- return then ? then(value) : value;
2737
- }
2738
- if (!value || !value.then) {
2739
- value = Promise.resolve(value);
2740
- }
2741
- return then ? value.then(then) : value;
2742
- }
2743
- function _invoke$1(body, then) {
2744
- var result = body();
2745
- if (result && result.then) {
2746
- return result.then(then);
2747
- }
2748
- return then(result);
2749
- }
2750
- function _catch$1(body, recover) {
2751
- try {
2752
- var result = body();
2753
- } catch (e) {
2754
- return recover(e);
2755
- }
2756
- if (result && result.then) {
2757
- return result.then(void 0, recover);
2758
- }
2759
- return result;
2760
- }
2761
- function _async$3(f) {
2762
- return function () {
2763
- for (var args = [], i = 0; i < arguments.length; i++) {
2764
- args[i] = arguments[i];
2765
- }
2766
- try {
2767
- return Promise.resolve(f.apply(this, args));
2768
- } catch (e) {
2769
- return Promise.reject(e);
2770
- }
2771
- };
2772
- }
2773
3212
  const ZOHO_SUCCESS_CODE = 'SUCCESS';
2774
3213
  function zohoServerErrorData(error) {
2775
3214
  const errorType = typeof error;
@@ -2841,24 +3280,20 @@ function logZohoServerErrorFunction(zohoApiNamePrefix) {
2841
3280
  */
2842
3281
  function handleZohoErrorFetchFactory(parseZohoError, defaultLogError) {
2843
3282
  return (fetch$1, logError = defaultLogError) => {
2844
- return _async$3(function (x, y) {
2845
- return _catch$1(function () {
2846
- return _await$3(fetch$1(x, y)); // await to catch thrown errors
2847
- }, function (e) {
2848
- return _invoke$1(function () {
2849
- if (e instanceof fetch.FetchResponseError) {
2850
- return _await$3(parseZohoError(e), function (error) {
2851
- if (error) {
2852
- logError(error); // log before throwing.
2853
- throw error;
2854
- }
2855
- });
3283
+ return async (x, y) => {
3284
+ try {
3285
+ return await fetch$1(x, y); // await to catch thrown errors
3286
+ } catch (e) {
3287
+ if (e instanceof fetch.FetchResponseError) {
3288
+ const error = await parseZohoError(e);
3289
+ if (error) {
3290
+ logError(error); // log before throwing.
3291
+ throw error;
2856
3292
  }
2857
- }, function (_result) {
2858
- throw e;
2859
- });
2860
- });
2861
- });
3293
+ }
3294
+ throw e;
3295
+ }
3296
+ };
2862
3297
  };
2863
3298
  }
2864
3299
  /**
@@ -3010,37 +3445,6 @@ function tryFindZohoServerErrorData(errorResponseData, responseError) {
3010
3445
  /**
3011
3446
  * Thrown when a record with the given id has no content. Typically also means it does not exist.
3012
3447
  */
3013
-
3014
- function _await$2(value, then, direct) {
3015
- if (direct) {
3016
- return then ? then(value) : value;
3017
- }
3018
- if (!value || !value.then) {
3019
- value = Promise.resolve(value);
3020
- }
3021
- return then ? value.then(then) : value;
3022
- }
3023
- function _async$2(f) {
3024
- return function () {
3025
- for (var args = [], i = 0; i < arguments.length; i++) {
3026
- args[i] = arguments[i];
3027
- }
3028
- try {
3029
- return Promise.resolve(f.apply(this, args));
3030
- } catch (e) {
3031
- return Promise.reject(e);
3032
- }
3033
- };
3034
- }
3035
- const parseZohoRecruitError = _async$2(function (responseError) {
3036
- return _await$2(responseError.response.json().catch(x => undefined), function (data) {
3037
- let result;
3038
- if (data) {
3039
- result = parseZohoRecruitServerErrorResponseData(data, responseError);
3040
- }
3041
- return result;
3042
- });
3043
- });
3044
3448
  class ZohoRecruitRecordNoContentError extends makeError.BaseError {
3045
3449
  constructor(moduleName, recordId) {
3046
3450
  super(`There was no content or matching records for the content. It may not exist.`);
@@ -3093,6 +3497,14 @@ function assertRecordDataArrayResultHasContent(moduleName, recordId) {
3093
3497
  };
3094
3498
  }
3095
3499
  const logZohoRecruitErrorToConsole = logZohoServerErrorFunction('ZohoRecruit');
3500
+ async function parseZohoRecruitError(responseError) {
3501
+ const data = await responseError.response.json().catch(x => undefined);
3502
+ let result;
3503
+ if (data) {
3504
+ result = parseZohoRecruitServerErrorResponseData(data, responseError);
3505
+ }
3506
+ return result;
3507
+ }
3096
3508
  function parseZohoRecruitServerErrorResponseData(errorResponseData, responseError) {
3097
3509
  let result;
3098
3510
  const error = tryFindZohoServerErrorData(errorResponseData, responseError);
@@ -3342,41 +3754,219 @@ function zohoRecruitMultiRecordResult(input, results) {
3342
3754
  return result;
3343
3755
  }
3344
3756
 
3345
- /**
3346
- * Error in the following cases:
3347
- * - the refresh token string is invalid
3348
- */
3757
+ var defineProperty = objectDefineProperty.f;
3758
+
3759
+ var proxyAccessor$1 = function (Target, Source, key) {
3760
+ key in Target || defineProperty(Target, key, {
3761
+ configurable: true,
3762
+ get: function () { return Source[key]; },
3763
+ set: function (it) { Source[key] = it; }
3764
+ });
3765
+ };
3766
+
3767
+ var isCallable = isCallable$k;
3768
+ var isObject$1 = isObject$d;
3769
+ var setPrototypeOf$1 = objectSetPrototypeOf;
3770
+
3771
+ // makes subclassing work correct for wrapped built-ins
3772
+ var inheritIfRequired$1 = function ($this, dummy, Wrapper) {
3773
+ var NewTarget, NewTargetPrototype;
3774
+ if (
3775
+ // it can work only with native `setPrototypeOf`
3776
+ setPrototypeOf$1 &&
3777
+ // we haven't completely correct pre-ES6 way for getting `new.target`, so use this
3778
+ isCallable(NewTarget = dummy.constructor) &&
3779
+ NewTarget !== Wrapper &&
3780
+ isObject$1(NewTargetPrototype = NewTarget.prototype) &&
3781
+ NewTargetPrototype !== Wrapper.prototype
3782
+ ) setPrototypeOf$1($this, NewTargetPrototype);
3783
+ return $this;
3784
+ };
3785
+
3786
+ var toString = toString$1;
3349
3787
 
3350
- function _await$1(value, then, direct) {
3351
- if (direct) {
3352
- return then ? then(value) : value;
3788
+ var normalizeStringArgument$1 = function (argument, $default) {
3789
+ return argument === undefined ? arguments.length < 2 ? '' : $default : toString(argument);
3790
+ };
3791
+
3792
+ var isObject = isObject$d;
3793
+ var createNonEnumerableProperty$2 = createNonEnumerableProperty$6;
3794
+
3795
+ // `InstallErrorCause` abstract operation
3796
+ // https://tc39.es/proposal-error-cause/#sec-errorobjects-install-error-cause
3797
+ var installErrorCause$1 = function (O, options) {
3798
+ if (isObject(options) && 'cause' in options) {
3799
+ createNonEnumerableProperty$2(O, 'cause', options.cause);
3353
3800
  }
3354
- if (!value || !value.then) {
3355
- value = Promise.resolve(value);
3801
+ };
3802
+
3803
+ var uncurryThis = functionUncurryThis;
3804
+
3805
+ var $Error = Error;
3806
+ var replace = uncurryThis(''.replace);
3807
+
3808
+ var TEST = (function (arg) { return String(new $Error(arg).stack); })('zxcasd');
3809
+ // eslint-disable-next-line redos/no-vulnerable -- safe
3810
+ var V8_OR_CHAKRA_STACK_ENTRY = /\n\s*at [^:]*:[^\n]*/;
3811
+ var IS_V8_OR_CHAKRA_STACK = V8_OR_CHAKRA_STACK_ENTRY.test(TEST);
3812
+
3813
+ var errorStackClear = function (stack, dropEntries) {
3814
+ if (IS_V8_OR_CHAKRA_STACK && typeof stack == 'string' && !$Error.prepareStackTrace) {
3815
+ while (dropEntries--) stack = replace(stack, V8_OR_CHAKRA_STACK_ENTRY, '');
3816
+ } return stack;
3817
+ };
3818
+
3819
+ var fails = fails$h;
3820
+ var createPropertyDescriptor = createPropertyDescriptor$4;
3821
+
3822
+ var errorStackInstallable = !fails(function () {
3823
+ var error = new Error('a');
3824
+ if (!('stack' in error)) return true;
3825
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
3826
+ Object.defineProperty(error, 'stack', createPropertyDescriptor(1, 7));
3827
+ return error.stack !== 7;
3828
+ });
3829
+
3830
+ var createNonEnumerableProperty$1 = createNonEnumerableProperty$6;
3831
+ var clearErrorStack = errorStackClear;
3832
+ var ERROR_STACK_INSTALLABLE = errorStackInstallable;
3833
+
3834
+ // non-standard V8
3835
+ var captureStackTrace = Error.captureStackTrace;
3836
+
3837
+ var errorStackInstall = function (error, C, stack, dropEntries) {
3838
+ if (ERROR_STACK_INSTALLABLE) {
3839
+ if (captureStackTrace) captureStackTrace(error, C);
3840
+ else createNonEnumerableProperty$1(error, 'stack', clearErrorStack(stack, dropEntries));
3356
3841
  }
3357
- return then ? value.then(then) : value;
3358
- }
3359
- function _async$1(f) {
3360
- return function () {
3361
- for (var args = [], i = 0; i < arguments.length; i++) {
3362
- args[i] = arguments[i];
3363
- }
3364
- try {
3365
- return Promise.resolve(f.apply(this, args));
3366
- } catch (e) {
3367
- return Promise.reject(e);
3368
- }
3369
- };
3370
- }
3371
- const parseZohoAccountsError = _async$1(function (responseError) {
3372
- return _await$1(responseError.response.json().catch(x => undefined), function (data) {
3373
- let result;
3374
- if (data) {
3375
- result = parseZohoAccountsServerErrorResponseData(data, responseError);
3376
- }
3842
+ };
3843
+
3844
+ var getBuiltIn = getBuiltIn$8;
3845
+ var hasOwn = hasOwnProperty_1;
3846
+ var createNonEnumerableProperty = createNonEnumerableProperty$6;
3847
+ var isPrototypeOf = objectIsPrototypeOf;
3848
+ var setPrototypeOf = objectSetPrototypeOf;
3849
+ var copyConstructorProperties = copyConstructorProperties$2;
3850
+ var proxyAccessor = proxyAccessor$1;
3851
+ var inheritIfRequired = inheritIfRequired$1;
3852
+ var normalizeStringArgument = normalizeStringArgument$1;
3853
+ var installErrorCause = installErrorCause$1;
3854
+ var installErrorStack = errorStackInstall;
3855
+ var DESCRIPTORS = descriptors;
3856
+
3857
+ var wrapErrorConstructorWithCause$1 = function (FULL_NAME, wrapper, FORCED, IS_AGGREGATE_ERROR) {
3858
+ var STACK_TRACE_LIMIT = 'stackTraceLimit';
3859
+ var OPTIONS_POSITION = IS_AGGREGATE_ERROR ? 2 : 1;
3860
+ var path = FULL_NAME.split('.');
3861
+ var ERROR_NAME = path[path.length - 1];
3862
+ var OriginalError = getBuiltIn.apply(null, path);
3863
+
3864
+ if (!OriginalError) return;
3865
+
3866
+ var OriginalErrorPrototype = OriginalError.prototype;
3867
+
3868
+ // V8 9.3- bug https://bugs.chromium.org/p/v8/issues/detail?id=12006
3869
+ if (hasOwn(OriginalErrorPrototype, 'cause')) delete OriginalErrorPrototype.cause;
3870
+
3871
+ if (!FORCED) return OriginalError;
3872
+
3873
+ var BaseError = getBuiltIn('Error');
3874
+
3875
+ var WrappedError = wrapper(function (a, b) {
3876
+ var message = normalizeStringArgument(IS_AGGREGATE_ERROR ? b : a, undefined);
3877
+ var result = IS_AGGREGATE_ERROR ? new OriginalError(a) : new OriginalError();
3878
+ if (message !== undefined) createNonEnumerableProperty(result, 'message', message);
3879
+ installErrorStack(result, WrappedError, result.stack, 2);
3880
+ if (this && isPrototypeOf(OriginalErrorPrototype, this)) inheritIfRequired(result, this, WrappedError);
3881
+ if (arguments.length > OPTIONS_POSITION) installErrorCause(result, arguments[OPTIONS_POSITION]);
3377
3882
  return result;
3378
3883
  });
3884
+
3885
+ WrappedError.prototype = OriginalErrorPrototype;
3886
+
3887
+ if (ERROR_NAME !== 'Error') {
3888
+ if (setPrototypeOf) setPrototypeOf(WrappedError, BaseError);
3889
+ else copyConstructorProperties(WrappedError, BaseError, { name: true });
3890
+ } else if (DESCRIPTORS && STACK_TRACE_LIMIT in OriginalError) {
3891
+ proxyAccessor(WrappedError, OriginalError, STACK_TRACE_LIMIT);
3892
+ proxyAccessor(WrappedError, OriginalError, 'prepareStackTrace');
3893
+ }
3894
+
3895
+ copyConstructorProperties(WrappedError, OriginalError);
3896
+
3897
+ try {
3898
+ // Safari 13- bug: WebAssembly errors does not have a proper `.name`
3899
+ if (OriginalErrorPrototype.name !== ERROR_NAME) {
3900
+ createNonEnumerableProperty(OriginalErrorPrototype, 'name', ERROR_NAME);
3901
+ }
3902
+ OriginalErrorPrototype.constructor = WrappedError;
3903
+ } catch (error) { /* empty */ }
3904
+
3905
+ return WrappedError;
3906
+ };
3907
+
3908
+ /* eslint-disable no-unused-vars -- required for functions `.length` */
3909
+ var $ = _export;
3910
+ var global$1 = global$j;
3911
+ var apply = functionApply;
3912
+ var wrapErrorConstructorWithCause = wrapErrorConstructorWithCause$1;
3913
+
3914
+ var WEB_ASSEMBLY = 'WebAssembly';
3915
+ var WebAssembly = global$1[WEB_ASSEMBLY];
3916
+
3917
+ // eslint-disable-next-line es/no-error-cause -- feature detection
3918
+ var FORCED = new Error('e', { cause: 7 }).cause !== 7;
3919
+
3920
+ var exportGlobalErrorCauseWrapper = function (ERROR_NAME, wrapper) {
3921
+ var O = {};
3922
+ O[ERROR_NAME] = wrapErrorConstructorWithCause(ERROR_NAME, wrapper, FORCED);
3923
+ $({ global: true, constructor: true, arity: 1, forced: FORCED }, O);
3924
+ };
3925
+
3926
+ var exportWebAssemblyErrorCauseWrapper = function (ERROR_NAME, wrapper) {
3927
+ if (WebAssembly && WebAssembly[ERROR_NAME]) {
3928
+ var O = {};
3929
+ O[ERROR_NAME] = wrapErrorConstructorWithCause(WEB_ASSEMBLY + '.' + ERROR_NAME, wrapper, FORCED);
3930
+ $({ target: WEB_ASSEMBLY, stat: true, constructor: true, arity: 1, forced: FORCED }, O);
3931
+ }
3932
+ };
3933
+
3934
+ // https://tc39.es/ecma262/#sec-nativeerror
3935
+ exportGlobalErrorCauseWrapper('Error', function (init) {
3936
+ return function Error(message) { return apply(init, this, arguments); };
3937
+ });
3938
+ exportGlobalErrorCauseWrapper('EvalError', function (init) {
3939
+ return function EvalError(message) { return apply(init, this, arguments); };
3940
+ });
3941
+ exportGlobalErrorCauseWrapper('RangeError', function (init) {
3942
+ return function RangeError(message) { return apply(init, this, arguments); };
3943
+ });
3944
+ exportGlobalErrorCauseWrapper('ReferenceError', function (init) {
3945
+ return function ReferenceError(message) { return apply(init, this, arguments); };
3946
+ });
3947
+ exportGlobalErrorCauseWrapper('SyntaxError', function (init) {
3948
+ return function SyntaxError(message) { return apply(init, this, arguments); };
3379
3949
  });
3950
+ exportGlobalErrorCauseWrapper('TypeError', function (init) {
3951
+ return function TypeError(message) { return apply(init, this, arguments); };
3952
+ });
3953
+ exportGlobalErrorCauseWrapper('URIError', function (init) {
3954
+ return function URIError(message) { return apply(init, this, arguments); };
3955
+ });
3956
+ exportWebAssemblyErrorCauseWrapper('CompileError', function (init) {
3957
+ return function CompileError(message) { return apply(init, this, arguments); };
3958
+ });
3959
+ exportWebAssemblyErrorCauseWrapper('LinkError', function (init) {
3960
+ return function LinkError(message) { return apply(init, this, arguments); };
3961
+ });
3962
+ exportWebAssemblyErrorCauseWrapper('RuntimeError', function (init) {
3963
+ return function RuntimeError(message) { return apply(init, this, arguments); };
3964
+ });
3965
+
3966
+ /**
3967
+ * Error in the following cases:
3968
+ * - the refresh token string is invalid
3969
+ */
3380
3970
  const ZOHO_ACCOUNTS_INVALID_CODE_ERROR_CODE = 'invalid_code';
3381
3971
  const ZOHO_ACCOUNTS_INVALID_CLIENT_ERROR_CODE = 'invalid_client';
3382
3972
  /**
@@ -3400,6 +3990,14 @@ class ZohoAccountsAuthFailureError extends fetch.FetchRequestFactoryError {
3400
3990
  }
3401
3991
  }
3402
3992
  const logZohoAccountsErrorToConsole = logZohoServerErrorFunction('ZohoAccounts');
3993
+ async function parseZohoAccountsError(responseError) {
3994
+ const data = await responseError.response.json().catch(x => undefined);
3995
+ let result;
3996
+ if (data) {
3997
+ result = parseZohoAccountsServerErrorResponseData(data, responseError);
3998
+ }
3999
+ return result;
4000
+ }
3403
4001
  function parseZohoAccountsServerErrorResponseData(errorResponseData, responseError) {
3404
4002
  let result;
3405
4003
  const error = errorResponseData.error;
@@ -3423,26 +4021,13 @@ const handleZohoAccountsErrorFetch = handleZohoErrorFetchFactory(parseZohoAccoun
3423
4021
  /**
3424
4022
  * Generates a new ZohoAccessTokenStringFactory.
3425
4023
  */
3426
-
3427
- function _call$2(body, then, direct) {
3428
- if (direct) {
3429
- return then ? then(body()) : body();
3430
- }
3431
- try {
3432
- var result = Promise.resolve(body());
3433
- return then ? result.then(then) : result;
3434
- } catch (e) {
3435
- return Promise.reject(e);
3436
- }
3437
- }
3438
4024
  function zohoAccessTokenStringFactory(zohoAccessTokenFactory) {
3439
- return function () {
3440
- return _call$2(zohoAccessTokenFactory, function (token) {
3441
- if (!(token != null && token.accessToken)) {
3442
- throw new ZohoAccountsAuthFailureError();
3443
- }
3444
- return token.accessToken;
3445
- });
4025
+ return async () => {
4026
+ const token = await zohoAccessTokenFactory();
4027
+ if (!(token != null && token.accessToken)) {
4028
+ throw new ZohoAccountsAuthFailureError();
4029
+ }
4030
+ return token.accessToken;
3446
4031
  };
3447
4032
  }
3448
4033
 
@@ -3458,6 +4043,7 @@ function zohoRateLimitedFetchHandler(config) {
3458
4043
  return {
3459
4044
  limit: defaultLimit,
3460
4045
  startLimitAt: Math.ceil(limit / 10),
4046
+ // can do 10% of the requests of the limit before rate limiting begins
3461
4047
  cooldownRate: 1.2 * (limit / (defaultResetPeriod / util.MS_IN_SECOND)),
3462
4048
  exponentRate: 1.08,
3463
4049
  maxWaitTime: util.MS_IN_SECOND * 10,
@@ -3503,17 +4089,6 @@ function zohoRateLimitedFetchHandler(config) {
3503
4089
  });
3504
4090
  }
3505
4091
 
3506
- function _call$1(body, then, direct) {
3507
- if (direct) {
3508
- return then ? then(body()) : body();
3509
- }
3510
- try {
3511
- var result = Promise.resolve(body());
3512
- return then ? result.then(then) : result;
3513
- } catch (e) {
3514
- return Promise.reject(e);
3515
- }
3516
- }
3517
4092
  function zohoRecruitFactory(factoryConfig) {
3518
4093
  const {
3519
4094
  accountsContext
@@ -3524,19 +4099,17 @@ function zohoRecruitFactory(factoryConfig) {
3524
4099
  logZohoServerErrorFunction,
3525
4100
  fetchFactory = input => fetch.fetchApiFetchService.makeFetch({
3526
4101
  baseUrl: input.apiUrl,
3527
- baseRequest: function () {
3528
- return _call$1(accessTokenStringFactory, function (_accessTokenStringFac) {
3529
- return {
3530
- headers: {
3531
- 'Content-Type': 'application/json',
3532
- Authorization: `Bearer ${_accessTokenStringFac}`
3533
- }
3534
- };
3535
- });
3536
- },
4102
+ baseRequest: async () => ({
4103
+ headers: {
4104
+ 'Content-Type': 'application/json',
4105
+ Authorization: `Bearer ${await accessTokenStringFactory()}`
4106
+ }
4107
+ }),
3537
4108
  fetchHandler,
3538
4109
  timeout: 20 * 1000,
4110
+ // 20 second timeout
3539
4111
  requireOkResponse: true,
4112
+ // enforce ok response
3540
4113
  useTimeout: true // use timeout
3541
4114
  })
3542
4115
  } = factoryConfig;
@@ -3551,6 +4124,7 @@ function zohoRecruitFactory(factoryConfig) {
3551
4124
  const fetch$1 = handleZohoRecruitErrorFetch(baseFetch, logZohoServerErrorFunction);
3552
4125
  const fetchJson = fetch.fetchJsonFunction(fetch$1, {
3553
4126
  interceptJsonResponse: interceptZohoRecruitErrorResponse,
4127
+ // intercept errors that return status 200
3554
4128
  handleFetchJsonParseErrorFunction: fetch.returnNullHandleFetchJsonParseErrorFunction
3555
4129
  });
3556
4130
  const recruitContext = {
@@ -3600,81 +4174,6 @@ function zohoAccountsConfigApiUrl(input) {
3600
4174
  }
3601
4175
  }
3602
4176
 
3603
- function _call(body, then, direct) {
3604
- if (direct) {
3605
- return then ? then(body()) : body();
3606
- }
3607
- try {
3608
- var result = Promise.resolve(body());
3609
- return then ? result.then(then) : result;
3610
- } catch (e) {
3611
- return Promise.reject(e);
3612
- }
3613
- } /**
3614
- * Creates a ZohoAccountsZohoAccessTokenFactoryConfig
3615
- *
3616
- * @param config
3617
- * @returns
3618
- */
3619
- function _async(f) {
3620
- return function () {
3621
- for (var args = [], i = 0; i < arguments.length; i++) {
3622
- args[i] = arguments[i];
3623
- }
3624
- try {
3625
- return Promise.resolve(f.apply(this, args));
3626
- } catch (e) {
3627
- return Promise.reject(e);
3628
- }
3629
- };
3630
- }
3631
- function _await(value, then, direct) {
3632
- if (direct) {
3633
- return then ? then(value) : value;
3634
- }
3635
- if (!value || !value.then) {
3636
- value = Promise.resolve(value);
3637
- }
3638
- return then ? value.then(then) : value;
3639
- }
3640
- function _catch(body, recover) {
3641
- try {
3642
- var result = body();
3643
- } catch (e) {
3644
- return recover(e);
3645
- }
3646
- if (result && result.then) {
3647
- return result.then(void 0, recover);
3648
- }
3649
- return result;
3650
- }
3651
- function _empty() {}
3652
- function _awaitIgnored(value, direct) {
3653
- if (!direct) {
3654
- return value && value.then ? value.then(_empty) : Promise.resolve();
3655
- }
3656
- }
3657
- function _continueIgnored(value) {
3658
- if (value && value.then) {
3659
- return value.then(_empty);
3660
- }
3661
- }
3662
- function _invokeIgnored(body) {
3663
- var result = body();
3664
- if (result && result.then) {
3665
- return result.then(_empty);
3666
- }
3667
- }
3668
- function _continue(value, then) {
3669
- return value && value.then ? value.then(then) : then(value);
3670
- }
3671
- function _invoke(body, then) {
3672
- var result = body();
3673
- if (result && result.then) {
3674
- return result.then(then);
3675
- }
3676
- return then(result);
3677
- }
3678
4177
  function zohoAccountsFactory(factoryConfig) {
3679
4178
  const fetchHandler = zohoRateLimitedFetchHandler();
3680
4179
  const {
@@ -3688,7 +4187,9 @@ function zohoAccountsFactory(factoryConfig) {
3688
4187
  },
3689
4188
  fetchHandler,
3690
4189
  timeout: 20 * 1000,
4190
+ // 20 second timeout
3691
4191
  requireOkResponse: true,
4192
+ // enforce ok response
3692
4193
  useTimeout: true // use timeout
3693
4194
  })
3694
4195
  } = factoryConfig;
@@ -3708,26 +4209,26 @@ function zohoAccountsFactory(factoryConfig) {
3708
4209
  const fetch$1 = handleZohoAccountsErrorFetch(baseFetch, logZohoServerErrorFunction);
3709
4210
  const fetchJson = fetch.fetchJsonFunction(fetch$1, {
3710
4211
  interceptJsonResponse: interceptZohoAccountsErrorResponse,
4212
+ // intercept errors that return status 200
3711
4213
  handleFetchJsonParseErrorFunction: fetch.returnNullHandleFetchJsonParseErrorFunction
3712
4214
  });
3713
- const tokenRefresher = _async(function () {
4215
+ const tokenRefresher = async () => {
3714
4216
  const createdAt = new Date().getTime();
3715
- return _call(accessToken(accountsContext), function ({
4217
+ const {
3716
4218
  access_token,
3717
4219
  api_domain,
3718
4220
  scope,
3719
4221
  expires_in
3720
- }) {
3721
- const result = {
3722
- accessToken: access_token,
3723
- apiDomain: api_domain,
3724
- expiresIn: expires_in,
3725
- expiresAt: new Date(createdAt + expires_in * util.MS_IN_SECOND),
3726
- scope
3727
- };
3728
- return result;
3729
- });
3730
- });
4222
+ } = await accessToken(accountsContext)();
4223
+ const result = {
4224
+ accessToken: access_token,
4225
+ apiDomain: api_domain,
4226
+ expiresIn: expires_in,
4227
+ expiresAt: new Date(createdAt + expires_in * util.MS_IN_SECOND),
4228
+ scope
4229
+ };
4230
+ return result;
4231
+ };
3731
4232
  const loadAccessToken = zohoAccountsZohoAccessTokenFactory({
3732
4233
  tokenRefresher,
3733
4234
  accessTokenCache: config.accessTokenCache
@@ -3746,6 +4247,12 @@ function zohoAccountsFactory(factoryConfig) {
3746
4247
  return zohoAccounts;
3747
4248
  };
3748
4249
  }
4250
+ /**
4251
+ * Creates a ZohoAccountsZohoAccessTokenFactoryConfig
4252
+ *
4253
+ * @param config
4254
+ * @returns
4255
+ */
3749
4256
  function zohoAccountsZohoAccessTokenFactory(config) {
3750
4257
  const {
3751
4258
  tokenRefresher,
@@ -3757,49 +4264,39 @@ function zohoAccountsZohoAccessTokenFactory(config) {
3757
4264
  * Caches the token internally here until it expires.
3758
4265
  */
3759
4266
  let currentToken = null;
3760
- return _async(function () {
4267
+ return async () => {
3761
4268
  // load from cache
3762
- return _invoke(function () {
3763
- if (!currentToken) {
3764
- return _await(accessTokenCache == null ? void 0 : accessTokenCache.loadCachedToken(), function (cachedToken) {
3765
- if (cachedToken) {
3766
- currentToken = cachedToken;
3767
- }
3768
- });
4269
+ if (!currentToken) {
4270
+ const cachedToken = await (accessTokenCache == null ? void 0 : accessTokenCache.loadCachedToken());
4271
+ if (cachedToken) {
4272
+ currentToken = cachedToken;
3769
4273
  }
3770
- }, function () {
3771
- // check expiration
3772
- if (currentToken != null) {
3773
- const isExpired = new Date().getTime() + tokenExpirationBuffer >= currentToken.expiresAt.getTime();
3774
- if (isExpired) {
3775
- currentToken = null;
3776
- }
4274
+ }
4275
+ // check expiration
4276
+ if (currentToken != null) {
4277
+ const isExpired = new Date().getTime() + tokenExpirationBuffer >= currentToken.expiresAt.getTime();
4278
+ if (isExpired) {
4279
+ currentToken = null;
4280
+ }
4281
+ }
4282
+ // load from source
4283
+ if (!currentToken) {
4284
+ try {
4285
+ currentToken = await tokenRefresher();
4286
+ } catch (e) {
4287
+ console.error(`zohoAccountsZohoAccessTokenFactory(): Failed retrieving new token from tokenRefresher: `, e);
4288
+ throw new ZohoAccountsAuthFailureError('Token Refresh Failed');
3777
4289
  }
3778
- // load from source
3779
- return _invoke(function () {
3780
- if (!currentToken) {
3781
- return _continue(_catch(function () {
3782
- return _call(tokenRefresher, function (_tokenRefresher) {
3783
- currentToken = _tokenRefresher;
3784
- });
3785
- }, function (e) {
3786
- console.error(`zohoAccountsZohoAccessTokenFactory(): Failed retrieving new token from tokenRefresher: `, e);
3787
- throw new ZohoAccountsAuthFailureError('Token Refresh Failed');
3788
- }), function (_result) {
3789
- return _invokeIgnored(function () {
3790
- if (currentToken) {
3791
- return _continueIgnored(_catch(function () {
3792
- return _awaitIgnored(accessTokenCache == null ? void 0 : accessTokenCache.updateCachedToken(currentToken));
3793
- }, _empty));
3794
- }
3795
- });
3796
- });
4290
+ if (currentToken) {
4291
+ try {
4292
+ await (accessTokenCache == null ? void 0 : accessTokenCache.updateCachedToken(currentToken));
4293
+ } catch (e) {
4294
+ // do nothing
3797
4295
  }
3798
- }, function (_result2) {
3799
- return currentToken;
3800
- });
3801
- });
3802
- });
4296
+ }
4297
+ }
4298
+ return currentToken;
4299
+ };
3803
4300
  }
3804
4301
 
3805
4302
  function safeZohoDateTimeString(date) {