@ohif/app 3.13.0-beta.8 → 3.13.0-beta.81

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.
Files changed (72) hide show
  1. package/dist/{1459.bundle.9fbac3c8e089c433777e.js → 1459.bundle.8dac0d666a38bfa74d75.js} +5 -6
  2. package/dist/{1608.bundle.0687c661f1c9edfb3b8a.js → 1608.bundle.26306ea38618db59eff7.js} +12 -12
  3. package/dist/{1927.bundle.3050588e95f43cf57cdd.js → 1927.bundle.be67b3aafe238ca9f191.js} +27 -38
  4. package/dist/{1933.bundle.7ae9ef1a7b5ed55d9550.js → 1933.bundle.98bb859a3903ca9f7073.js} +32 -27
  5. package/dist/{2018.bundle.b8f9fe454ee996818531.js → 2018.bundle.9a31f91584577a24862e.js} +18 -19
  6. package/dist/{6409.bundle.b36048896cb11c8571fb.js → 2075.bundle.ba9ac60662f1fa739378.js} +337 -261
  7. package/dist/{2108.bundle.e84aa8d858d8c4f2413e.js → 2108.bundle.aea8d3b39486dd5ab39e.js} +569 -558
  8. package/dist/{213.bundle.9cff7f3868971abefe05.js → 213.bundle.54412c1510ab6ac3e129.js} +3 -5
  9. package/dist/{2424.bundle.9c081095926163e359e0.js → 2424.bundle.a7c50eea1404f7706d03.js} +3 -5
  10. package/dist/{2516.bundle.1ea0988d309a757bb6da.js → 2516.bundle.f62228e9a800de8d4b31.js} +6 -6
  11. package/dist/{2701.bundle.12bd01a80a9f8ea4cd94.js → 2701.bundle.6873805ddfdccc7a8b1e.js} +10 -10
  12. package/dist/{9195.bundle.a749686750f08e4adf93.js → 2851.bundle.bbb7743b8a06e85a2d8b.js} +484 -177
  13. package/dist/{1730.bundle.4f947de94428632e2499.js → 3138.bundle.f0c27e0fa51e8e522a03.js} +16 -310
  14. package/dist/{3461.bundle.8ce95fd079101d3e01b6.js → 3461.bundle.b8e87344d06051ccab12.js} +131 -107
  15. package/dist/{147.bundle.37d627289453cb6c3937.js → 3754.bundle.d2435bb372912595708c.js} +486 -49
  16. package/dist/{4202.bundle.5a0f8e4004c5d8a68548.js → 4202.bundle.4fcd0de412907efd5b53.js} +6 -6
  17. package/dist/{4019.bundle.83a604779f7da0101ced.js → 4287.bundle.4f28e48c1e39a46dfc87.js} +352 -238
  18. package/dist/{5462.bundle.21beddaca145b7465c72.js → 4406.bundle.573d234b4641d23cf8db.js} +1083 -1308
  19. package/dist/{1403.bundle.f7392178d9262e1d99c2.js → 4507.bundle.48936299167b13472d81.js} +10 -305
  20. package/dist/{6347.bundle.784c48912700f281de1d.js → 4579.bundle.1c315389368cc476aed3.js} +1439 -1879
  21. package/dist/{4819.bundle.c0b6dd8690d5755fde43.js → 4819.bundle.1793d3fea8733ed305f7.js} +88 -53
  22. package/dist/{4775.bundle.5671e155db52c026a803.js → 5015.bundle.efefa774795b62cde37f.js} +29 -333
  23. package/dist/{5028.bundle.bc79f49125393ecc4f5f.js → 5028.bundle.41653a25d1fe816326d2.js} +11 -13
  24. package/dist/{5261.bundle.6e1a017f8f1027557f5b.js → 5261.bundle.2655560097e9250eac44.js} +412 -345
  25. package/dist/{5457.bundle.7720e5daa4e2bdff83ee.js → 5457.bundle.c34363f925f44fb40bbf.js} +16 -23
  26. package/dist/{5485.bundle.2c2a09db8c7a29258e9f.js → 5485.bundle.d829c2a13b08d0c13e94.js} +30 -36
  27. package/dist/{5491.bundle.2e01dd7ad29e4cc01bc1.js → 5491.bundle.4866d2ecb20dd089e071.js} +54 -51
  28. package/dist/{5802.bundle.3bf5e6b3ab330a594a47.js → 5802.bundle.cd36386cbe1613913ed4.js} +79 -20
  29. package/dist/5802.css +1 -1
  30. package/dist/{5830.bundle.b073c265c4fcea1afff3.js → 5830.bundle.791019deddd536980a11.js} +3 -3
  31. package/dist/{5858.bundle.ff6b340cf7457db76a1a.js → 5858.bundle.466e58128de344ab53f3.js} +90 -86
  32. package/dist/{6027.bundle.49a5c78a49ed6cd15f72.js → 6027.bundle.68fec283e9239785829d.js} +3 -5
  33. package/dist/{6354.bundle.c387737dc09c9cab4ff2.js → 6354.bundle.929febcf6d326e582e00.js} +151 -140
  34. package/dist/{6376.bundle.9cb74d7bc08476e2f1a7.js → 6376.bundle.527820a5cb1eece2a8d2.js} +6 -6
  35. package/dist/{2842.bundle.860b9f10fcdd9656947a.js → 6386.bundle.dc7e3b159d6b4733647f.js} +913 -2290
  36. package/dist/6939.bundle.41fbdef87597b5172ec6.js +3 -3
  37. package/dist/{7159.bundle.a5991a5d4f0dd8f1c95f.js → 7159.bundle.fb9df255868960f69765.js} +7 -5
  38. package/dist/{3081.bundle.30cd450e2dd213b1b978.js → 7166.bundle.d78a2e98bfcd9467f4c5.js} +1257 -467
  39. package/dist/{7190.bundle.e8f0193e0e06472f795c.js → 7190.bundle.479332d662ffe08d1f92.js} +1228 -855
  40. package/dist/{732.bundle.6978ac30a1e36abf06db.js → 732.bundle.ea6f9d8504e37e01a208.js} +5 -13
  41. package/dist/{7431.bundle.b01791d10e6cf9f503b0.js → 7431.bundle.a9b4dbf97a8c196efe51.js} +28 -28
  42. package/dist/{4410.bundle.c5224cd7d6238a7d4660.js → 7537.bundle.88314e5a6269f96a0bae.js} +5226 -2250
  43. package/dist/{7639.bundle.78e54c6f8dee95f4a6b7.js → 7639.bundle.0894138f5a71ebb77573.js} +3 -5
  44. package/dist/7758.bundle.c8d106364298e7d288f0.js +3 -3
  45. package/dist/{8094.bundle.5c44190a325ac23e3e5c.js → 8094.bundle.148a66619607e37cbf19.js} +3 -4
  46. package/dist/{8305.bundle.d7423a538dca30c376ce.js → 8305.bundle.889f34636979b7d84c2f.js} +71 -66
  47. package/dist/{6163.bundle.ab7295912f610ef8b0eb.js → 8499.bundle.a5bcbdc972c96cc2a9b8.js} +7 -302
  48. package/dist/8499.css +2 -0
  49. package/dist/{85.bundle.0efe2e23b40b836a1fc1.js → 85.bundle.12227ce146b7ba52a74b.js} +3 -5
  50. package/dist/{8558.bundle.53e0018bbb77300516b5.js → 8558.bundle.71a05b3a3031e9638f52.js} +15 -309
  51. package/dist/{8583.bundle.4658de27c0d59037cc9b.js → 8583.bundle.ba19b136c21afeebaed0.js} +24 -27
  52. package/dist/{997.bundle.822b33e561263084e18c.js → 9039.bundle.f5db80328c99cd11293b.js} +4086 -3015
  53. package/dist/{7412.bundle.fab1742191b7fe937330.js → 9205.bundle.f2121894550d46d17398.js} +6180 -3330
  54. package/dist/{3584.bundle.8cc0750425513433e9cc.js → 9567.bundle.ff782480a4c66e306027.js} +3751 -2856
  55. package/dist/{9845.bundle.255e7c7f7a88193b4e47.js → 9845.bundle.8c450e8d65a78a5afcd3.js} +10 -10
  56. package/dist/{9862.bundle.3a8958a82c572015d25d.js → 9862.bundle.6d793a997f85d73002e9.js} +8 -6
  57. package/dist/{9927.bundle.34fec2c87a385cd104be.js → 9927.bundle.f9f850442da32cf50f8a.js} +8 -6
  58. package/dist/app-config.js +12 -0
  59. package/dist/{app.bundle.43da7d5a1360d749cf34.js → app.bundle.bee5d88f966ce61e1d93.js} +65888 -62863
  60. package/dist/app.bundle.css +3 -3
  61. package/dist/{polySeg.bundle.a5aa9130b4191253c410.js → compute.bundle.5e9691bc58308d865058.js} +8 -20
  62. package/dist/{histogram-worker.bundle.d4e40a8018d2698b072e.js → histogram-worker.bundle.a2a50c4674d99c619ca7.js} +11 -23
  63. package/dist/index.html +1 -1
  64. package/dist/{interpolation.bundle.c70cb95d164dc494e6dc.js → interpolation.bundle.829844ff3f72f5645f29.js} +14 -26
  65. package/dist/{compute.bundle.64280c7af19ff567465f.js → polySeg.bundle.c394421c24d8c27d54ca.js} +10 -22
  66. package/dist/sw.js +1 -1
  67. package/package.json +23 -22
  68. package/dist/3343.bundle.d7578ce8f75d158c0bab.js +0 -297
  69. /package/dist/{1730.css → 3138.css} +0 -0
  70. /package/dist/{147.css → 3754.css} +0 -0
  71. /package/dist/{3343.css → 4972.css} +0 -0
  72. /package/dist/{6163.css → 7829.css} +0 -0
@@ -1,7 +1,7 @@
1
1
  (globalThis["webpackChunk"] = globalThis["webpackChunk"] || []).push([[7190],{
2
2
 
3
- /***/ 54028:
4
- /***/ ((__unused_webpack_module, exports) => {
3
+ /***/ 54028
4
+ (__unused_webpack_module, exports) {
5
5
 
6
6
  "use strict";
7
7
 
@@ -156,10 +156,10 @@ function fromByteArray (uint8) {
156
156
  }
157
157
 
158
158
 
159
- /***/ }),
159
+ /***/ },
160
160
 
161
- /***/ 81429:
162
- /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
161
+ /***/ 81429
162
+ (__unused_webpack_module, exports, __webpack_require__) {
163
163
 
164
164
  "use strict";
165
165
  var __webpack_unused_export__;
@@ -1982,10 +1982,10 @@ var hexSliceLookupTable = (function () {
1982
1982
  })()
1983
1983
 
1984
1984
 
1985
- /***/ }),
1985
+ /***/ },
1986
1986
 
1987
- /***/ 55801:
1988
- /***/ ((__unused_webpack_module, exports) => {
1987
+ /***/ 55801
1988
+ (__unused_webpack_module, exports) {
1989
1989
 
1990
1990
  /*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
1991
1991
  exports.read = function (buffer, offset, isLE, mLen, nBytes) {
@@ -2074,10 +2074,10 @@ exports.write = function (buffer, value, offset, isLE, mLen, nBytes) {
2074
2074
  }
2075
2075
 
2076
2076
 
2077
- /***/ }),
2077
+ /***/ },
2078
2078
 
2079
- /***/ 17739:
2080
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
2079
+ /***/ 17739
2080
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
2081
2081
 
2082
2082
  "use strict";
2083
2083
 
@@ -2154,7 +2154,7 @@ const { isArray } = Array;
2154
2154
  *
2155
2155
  * @returns {boolean} True if the value is undefined, otherwise false
2156
2156
  */
2157
- const isUndefined = typeOfTest("undefined");
2157
+ const isUndefined = typeOfTest('undefined');
2158
2158
 
2159
2159
  /**
2160
2160
  * Determine if a value is a Buffer
@@ -2181,7 +2181,7 @@ function isBuffer(val) {
2181
2181
  *
2182
2182
  * @returns {boolean} True if value is an ArrayBuffer, otherwise false
2183
2183
  */
2184
- const isArrayBuffer = kindOfTest("ArrayBuffer");
2184
+ const isArrayBuffer = kindOfTest('ArrayBuffer');
2185
2185
 
2186
2186
  /**
2187
2187
  * Determine if a value is a view on an ArrayBuffer
@@ -2192,7 +2192,7 @@ const isArrayBuffer = kindOfTest("ArrayBuffer");
2192
2192
  */
2193
2193
  function isArrayBufferView(val) {
2194
2194
  let result;
2195
- if (typeof ArrayBuffer !== "undefined" && ArrayBuffer.isView) {
2195
+ if (typeof ArrayBuffer !== 'undefined' && ArrayBuffer.isView) {
2196
2196
  result = ArrayBuffer.isView(val);
2197
2197
  } else {
2198
2198
  result = val && val.buffer && isArrayBuffer(val.buffer);
@@ -2207,7 +2207,7 @@ function isArrayBufferView(val) {
2207
2207
  *
2208
2208
  * @returns {boolean} True if value is a String, otherwise false
2209
2209
  */
2210
- const isString = typeOfTest("string");
2210
+ const isString = typeOfTest('string');
2211
2211
 
2212
2212
  /**
2213
2213
  * Determine if a value is a Function
@@ -2215,7 +2215,7 @@ const isString = typeOfTest("string");
2215
2215
  * @param {*} val The value to test
2216
2216
  * @returns {boolean} True if value is a Function, otherwise false
2217
2217
  */
2218
- const isFunction = typeOfTest("function");
2218
+ const isFunction = typeOfTest('function');
2219
2219
 
2220
2220
  /**
2221
2221
  * Determine if a value is a Number
@@ -2224,7 +2224,7 @@ const isFunction = typeOfTest("function");
2224
2224
  *
2225
2225
  * @returns {boolean} True if value is a Number, otherwise false
2226
2226
  */
2227
- const isNumber = typeOfTest("number");
2227
+ const isNumber = typeOfTest('number');
2228
2228
 
2229
2229
  /**
2230
2230
  * Determine if a value is an Object
@@ -2233,7 +2233,7 @@ const isNumber = typeOfTest("number");
2233
2233
  *
2234
2234
  * @returns {boolean} True if value is an Object, otherwise false
2235
2235
  */
2236
- const isObject = (thing) => thing !== null && typeof thing === "object";
2236
+ const isObject = (thing) => thing !== null && typeof thing === 'object';
2237
2237
 
2238
2238
  /**
2239
2239
  * Determine if a value is a Boolean
@@ -2251,7 +2251,7 @@ const isBoolean = (thing) => thing === true || thing === false;
2251
2251
  * @returns {boolean} True if value is a plain Object, otherwise false
2252
2252
  */
2253
2253
  const isPlainObject = (val) => {
2254
- if (kindOf(val) !== "object") {
2254
+ if (kindOf(val) !== 'object') {
2255
2255
  return false;
2256
2256
  }
2257
2257
 
@@ -2279,10 +2279,7 @@ const isEmptyObject = (val) => {
2279
2279
  }
2280
2280
 
2281
2281
  try {
2282
- return (
2283
- Object.keys(val).length === 0 &&
2284
- Object.getPrototypeOf(val) === Object.prototype
2285
- );
2282
+ return Object.keys(val).length === 0 && Object.getPrototypeOf(val) === Object.prototype;
2286
2283
  } catch (e) {
2287
2284
  // Fallback for any other objects that might cause RangeError with Object.keys()
2288
2285
  return false;
@@ -2296,7 +2293,7 @@ const isEmptyObject = (val) => {
2296
2293
  *
2297
2294
  * @returns {boolean} True if value is a Date, otherwise false
2298
2295
  */
2299
- const isDate = kindOfTest("Date");
2296
+ const isDate = kindOfTest('Date');
2300
2297
 
2301
2298
  /**
2302
2299
  * Determine if a value is a File
@@ -2305,7 +2302,32 @@ const isDate = kindOfTest("Date");
2305
2302
  *
2306
2303
  * @returns {boolean} True if value is a File, otherwise false
2307
2304
  */
2308
- const isFile = kindOfTest("File");
2305
+ const isFile = kindOfTest('File');
2306
+
2307
+ /**
2308
+ * Determine if a value is a React Native Blob
2309
+ * React Native "blob": an object with a `uri` attribute. Optionally, it can
2310
+ * also have a `name` and `type` attribute to specify filename and content type
2311
+ *
2312
+ * @see https://github.com/facebook/react-native/blob/26684cf3adf4094eb6c405d345a75bf8c7c0bf88/Libraries/Network/FormData.js#L68-L71
2313
+ *
2314
+ * @param {*} value The value to test
2315
+ *
2316
+ * @returns {boolean} True if value is a React Native Blob, otherwise false
2317
+ */
2318
+ const isReactNativeBlob = (value) => {
2319
+ return !!(value && typeof value.uri !== 'undefined');
2320
+ }
2321
+
2322
+ /**
2323
+ * Determine if environment is React Native
2324
+ * ReactNative `FormData` has a non-standard `getParts()` method
2325
+ *
2326
+ * @param {*} formData The formData to test
2327
+ *
2328
+ * @returns {boolean} True if environment is React Native, otherwise false
2329
+ */
2330
+ const isReactNative = (formData) => formData && typeof formData.getParts !== 'undefined';
2309
2331
 
2310
2332
  /**
2311
2333
  * Determine if a value is a Blob
@@ -2314,7 +2336,7 @@ const isFile = kindOfTest("File");
2314
2336
  *
2315
2337
  * @returns {boolean} True if value is a Blob, otherwise false
2316
2338
  */
2317
- const isBlob = kindOfTest("Blob");
2339
+ const isBlob = kindOfTest('Blob');
2318
2340
 
2319
2341
  /**
2320
2342
  * Determine if a value is a FileList
@@ -2323,7 +2345,7 @@ const isBlob = kindOfTest("Blob");
2323
2345
  *
2324
2346
  * @returns {boolean} True if value is a File, otherwise false
2325
2347
  */
2326
- const isFileList = kindOfTest("FileList");
2348
+ const isFileList = kindOfTest('FileList');
2327
2349
 
2328
2350
  /**
2329
2351
  * Determine if a value is a Stream
@@ -2341,18 +2363,28 @@ const isStream = (val) => isObject(val) && isFunction(val.pipe);
2341
2363
  *
2342
2364
  * @returns {boolean} True if value is an FormData, otherwise false
2343
2365
  */
2366
+ function getGlobal() {
2367
+ if (typeof globalThis !== 'undefined') return globalThis;
2368
+ if (typeof self !== 'undefined') return self;
2369
+ if (typeof window !== 'undefined') return window;
2370
+ if (typeof globalThis !== 'undefined') return globalThis;
2371
+ return {};
2372
+ }
2373
+
2374
+ const G = getGlobal();
2375
+ const FormDataCtor = typeof G.FormData !== 'undefined' ? G.FormData : undefined;
2376
+
2344
2377
  const isFormData = (thing) => {
2345
- let kind;
2346
- return (
2347
- thing &&
2348
- ((typeof FormData === "function" && thing instanceof FormData) ||
2349
- (isFunction(thing.append) &&
2350
- ((kind = kindOf(thing)) === "formdata" ||
2351
- // detect form-data instance
2352
- (kind === "object" &&
2353
- isFunction(thing.toString) &&
2354
- thing.toString() === "[object FormData]"))))
2355
- );
2378
+ if (!thing) return false;
2379
+ if (FormDataCtor && thing instanceof FormDataCtor) return true;
2380
+ // Reject plain objects inheriting directly from Object.prototype so prototype-pollution gadgets can't spoof FormData (GHSA-6chq-wfr3-2hj9).
2381
+ const proto = getPrototypeOf(thing);
2382
+ if (!proto || proto === Object.prototype) return false;
2383
+ if (!isFunction(thing.append)) return false;
2384
+ const kind = kindOf(thing);
2385
+ return kind === 'formdata' ||
2386
+ // detect form-data instance
2387
+ (kind === 'object' && isFunction(thing.toString) && thing.toString() === '[object FormData]');
2356
2388
  };
2357
2389
 
2358
2390
  /**
@@ -2362,13 +2394,13 @@ const isFormData = (thing) => {
2362
2394
  *
2363
2395
  * @returns {boolean} True if value is a URLSearchParams object, otherwise false
2364
2396
  */
2365
- const isURLSearchParams = kindOfTest("URLSearchParams");
2397
+ const isURLSearchParams = kindOfTest('URLSearchParams');
2366
2398
 
2367
2399
  const [isReadableStream, isRequest, isResponse, isHeaders] = [
2368
- "ReadableStream",
2369
- "Request",
2370
- "Response",
2371
- "Headers",
2400
+ 'ReadableStream',
2401
+ 'Request',
2402
+ 'Response',
2403
+ 'Headers',
2372
2404
  ].map(kindOfTest);
2373
2405
 
2374
2406
  /**
@@ -2378,9 +2410,9 @@ const [isReadableStream, isRequest, isResponse, isHeaders] = [
2378
2410
  *
2379
2411
  * @returns {String} The String freed of excess whitespace
2380
2412
  */
2381
- const trim = (str) =>
2382
- str.trim ? str.trim() : str.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
2383
-
2413
+ const trim = (str) => {
2414
+ return str.trim ? str.trim() : str.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, '');
2415
+ };
2384
2416
  /**
2385
2417
  * Iterate over an Array or an Object invoking a function for each item.
2386
2418
  *
@@ -2399,7 +2431,7 @@ const trim = (str) =>
2399
2431
  */
2400
2432
  function forEach(obj, fn, { allOwnKeys = false } = {}) {
2401
2433
  // Don't bother if no value provided
2402
- if (obj === null || typeof obj === "undefined") {
2434
+ if (obj === null || typeof obj === 'undefined') {
2403
2435
  return;
2404
2436
  }
2405
2437
 
@@ -2407,7 +2439,7 @@ function forEach(obj, fn, { allOwnKeys = false } = {}) {
2407
2439
  let l;
2408
2440
 
2409
2441
  // Force an array if not already something iterable
2410
- if (typeof obj !== "object") {
2442
+ if (typeof obj !== 'object') {
2411
2443
  /*eslint no-param-reassign:0*/
2412
2444
  obj = [obj];
2413
2445
  }
@@ -2424,9 +2456,7 @@ function forEach(obj, fn, { allOwnKeys = false } = {}) {
2424
2456
  }
2425
2457
 
2426
2458
  // Iterate over object keys
2427
- const keys = allOwnKeys
2428
- ? Object.getOwnPropertyNames(obj)
2429
- : Object.keys(obj);
2459
+ const keys = allOwnKeys ? Object.getOwnPropertyNames(obj) : Object.keys(obj);
2430
2460
  const len = keys.length;
2431
2461
  let key;
2432
2462
 
@@ -2437,6 +2467,14 @@ function forEach(obj, fn, { allOwnKeys = false } = {}) {
2437
2467
  }
2438
2468
  }
2439
2469
 
2470
+ /**
2471
+ * Finds a key in an object, case-insensitive, returning the actual key name.
2472
+ * Returns null if the object is a Buffer or if no match is found.
2473
+ *
2474
+ * @param {Object} obj - The object to search.
2475
+ * @param {string} key - The key to find (case-insensitive).
2476
+ * @returns {?string} The actual key name if found, otherwise null.
2477
+ */
2440
2478
  function findKey(obj, key) {
2441
2479
  if (isBuffer(obj)) {
2442
2480
  return null;
@@ -2457,16 +2495,11 @@ function findKey(obj, key) {
2457
2495
 
2458
2496
  const _global = (() => {
2459
2497
  /*eslint no-undef:0*/
2460
- if (typeof globalThis !== "undefined") return globalThis;
2461
- return typeof self !== "undefined"
2462
- ? self
2463
- : typeof window !== "undefined"
2464
- ? window
2465
- : global;
2498
+ if (typeof globalThis !== 'undefined') return globalThis;
2499
+ return typeof self !== 'undefined' ? self : typeof window !== 'undefined' ? window : globalThis;
2466
2500
  })();
2467
2501
 
2468
- const isContextDefined = (context) =>
2469
- !isUndefined(context) && context !== _global;
2502
+ const isContextDefined = (context) => !isUndefined(context) && context !== _global;
2470
2503
 
2471
2504
  /**
2472
2505
  * Accepts varargs expecting each argument to be an object, then
@@ -2491,7 +2524,7 @@ function merge(/* obj1, obj2, obj3, ... */) {
2491
2524
  const result = {};
2492
2525
  const assignValue = (val, key) => {
2493
2526
  // Skip dangerous property names to prevent prototype pollution
2494
- if (key === "__proto__" || key === "constructor" || key === "prototype") {
2527
+ if (key === '__proto__' || key === 'constructor' || key === 'prototype') {
2495
2528
  return;
2496
2529
  }
2497
2530
 
@@ -2544,7 +2577,7 @@ const extend = (a, b, thisArg, { allOwnKeys } = {}) => {
2544
2577
  });
2545
2578
  }
2546
2579
  },
2547
- { allOwnKeys },
2580
+ { allOwnKeys }
2548
2581
  );
2549
2582
  return a;
2550
2583
  };
@@ -2573,17 +2606,14 @@ const stripBOM = (content) => {
2573
2606
  * @returns {void}
2574
2607
  */
2575
2608
  const inherits = (constructor, superConstructor, props, descriptors) => {
2576
- constructor.prototype = Object.create(
2577
- superConstructor.prototype,
2578
- descriptors,
2579
- );
2580
- Object.defineProperty(constructor.prototype, "constructor", {
2609
+ constructor.prototype = Object.create(superConstructor.prototype, descriptors);
2610
+ Object.defineProperty(constructor.prototype, 'constructor', {
2581
2611
  value: constructor,
2582
2612
  writable: true,
2583
2613
  enumerable: false,
2584
2614
  configurable: true,
2585
2615
  });
2586
- Object.defineProperty(constructor, "super", {
2616
+ Object.defineProperty(constructor, 'super', {
2587
2617
  value: superConstructor.prototype,
2588
2618
  });
2589
2619
  props && Object.assign(constructor.prototype, props);
@@ -2613,20 +2643,13 @@ const toFlatObject = (sourceObj, destObj, filter, propFilter) => {
2613
2643
  i = props.length;
2614
2644
  while (i-- > 0) {
2615
2645
  prop = props[i];
2616
- if (
2617
- (!propFilter || propFilter(prop, sourceObj, destObj)) &&
2618
- !merged[prop]
2619
- ) {
2646
+ if ((!propFilter || propFilter(prop, sourceObj, destObj)) && !merged[prop]) {
2620
2647
  destObj[prop] = sourceObj[prop];
2621
2648
  merged[prop] = true;
2622
2649
  }
2623
2650
  }
2624
2651
  sourceObj = filter !== false && getPrototypeOf(sourceObj);
2625
- } while (
2626
- sourceObj &&
2627
- (!filter || filter(sourceObj, destObj)) &&
2628
- sourceObj !== Object.prototype
2629
- );
2652
+ } while (sourceObj && (!filter || filter(sourceObj, destObj)) && sourceObj !== Object.prototype);
2630
2653
 
2631
2654
  return destObj;
2632
2655
  };
@@ -2683,7 +2706,7 @@ const isTypedArray = ((TypedArray) => {
2683
2706
  return (thing) => {
2684
2707
  return TypedArray && thing instanceof TypedArray;
2685
2708
  };
2686
- })(typeof Uint8Array !== "undefined" && getPrototypeOf(Uint8Array));
2709
+ })(typeof Uint8Array !== 'undefined' && getPrototypeOf(Uint8Array));
2687
2710
 
2688
2711
  /**
2689
2712
  * For each entry in the object, call the function with the key and value.
@@ -2726,14 +2749,12 @@ const matchAll = (regExp, str) => {
2726
2749
  };
2727
2750
 
2728
2751
  /* Checking if the kindOfTest function returns true when passed an HTMLFormElement. */
2729
- const isHTMLForm = kindOfTest("HTMLFormElement");
2752
+ const isHTMLForm = kindOfTest('HTMLFormElement');
2730
2753
 
2731
2754
  const toCamelCase = (str) => {
2732
- return str
2733
- .toLowerCase()
2734
- .replace(/[-_\s]([a-z\d])(\w*)/g, function replacer(m, p1, p2) {
2735
- return p1.toUpperCase() + p2;
2736
- });
2755
+ return str.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g, function replacer(m, p1, p2) {
2756
+ return p1.toUpperCase() + p2;
2757
+ });
2737
2758
  };
2738
2759
 
2739
2760
  /* Creating a function that will check if an object has a property. */
@@ -2750,7 +2771,7 @@ const utils_hasOwnProperty = (
2750
2771
  *
2751
2772
  * @returns {boolean} True if value is a RegExp object, otherwise false
2752
2773
  */
2753
- const isRegExp = kindOfTest("RegExp");
2774
+ const isRegExp = kindOfTest('RegExp');
2754
2775
 
2755
2776
  const reduceDescriptors = (obj, reducer) => {
2756
2777
  const descriptors = Object.getOwnPropertyDescriptors(obj);
@@ -2774,10 +2795,7 @@ const reduceDescriptors = (obj, reducer) => {
2774
2795
  const freezeMethods = (obj) => {
2775
2796
  reduceDescriptors(obj, (descriptor, name) => {
2776
2797
  // skip restricted props in strict mode
2777
- if (
2778
- isFunction(obj) &&
2779
- ["arguments", "caller", "callee"].indexOf(name) !== -1
2780
- ) {
2798
+ if (isFunction(obj) && ['arguments', 'caller', 'callee'].indexOf(name) !== -1) {
2781
2799
  return false;
2782
2800
  }
2783
2801
 
@@ -2787,7 +2805,7 @@ const freezeMethods = (obj) => {
2787
2805
 
2788
2806
  descriptor.enumerable = false;
2789
2807
 
2790
- if ("writable" in descriptor) {
2808
+ if ('writable' in descriptor) {
2791
2809
  descriptor.writable = false;
2792
2810
  return;
2793
2811
  }
@@ -2800,6 +2818,14 @@ const freezeMethods = (obj) => {
2800
2818
  });
2801
2819
  };
2802
2820
 
2821
+ /**
2822
+ * Converts an array or a delimited string into an object set with values as keys and true as values.
2823
+ * Useful for fast membership checks.
2824
+ *
2825
+ * @param {Array|string} arrayOrString - The array or string to convert.
2826
+ * @param {string} delimiter - The delimiter to use if input is a string.
2827
+ * @returns {Object} An object with keys from the array or string, values set to true.
2828
+ */
2803
2829
  const toObjectSet = (arrayOrString, delimiter) => {
2804
2830
  const obj = {};
2805
2831
 
@@ -2809,9 +2835,7 @@ const toObjectSet = (arrayOrString, delimiter) => {
2809
2835
  });
2810
2836
  };
2811
2837
 
2812
- isArray(arrayOrString)
2813
- ? define(arrayOrString)
2814
- : define(String(arrayOrString).split(delimiter));
2838
+ isArray(arrayOrString) ? define(arrayOrString) : define(String(arrayOrString).split(delimiter));
2815
2839
 
2816
2840
  return obj;
2817
2841
  };
@@ -2819,9 +2843,7 @@ const toObjectSet = (arrayOrString, delimiter) => {
2819
2843
  const noop = () => {};
2820
2844
 
2821
2845
  const toFiniteNumber = (value, defaultValue) => {
2822
- return value != null && Number.isFinite((value = +value))
2823
- ? value
2824
- : defaultValue;
2846
+ return value != null && Number.isFinite((value = +value)) ? value : defaultValue;
2825
2847
  };
2826
2848
 
2827
2849
  /**
@@ -2835,11 +2857,17 @@ function isSpecCompliantForm(thing) {
2835
2857
  return !!(
2836
2858
  thing &&
2837
2859
  isFunction(thing.append) &&
2838
- thing[toStringTag] === "FormData" &&
2860
+ thing[toStringTag] === 'FormData' &&
2839
2861
  thing[iterator]
2840
2862
  );
2841
2863
  }
2842
2864
 
2865
+ /**
2866
+ * Recursively converts an object to a JSON-compatible object, handling circular references and Buffers.
2867
+ *
2868
+ * @param {Object} obj - The object to convert.
2869
+ * @returns {Object} The JSON-compatible object.
2870
+ */
2843
2871
  const toJSONObject = (obj) => {
2844
2872
  const stack = new Array(10);
2845
2873
 
@@ -2854,7 +2882,7 @@ const toJSONObject = (obj) => {
2854
2882
  return source;
2855
2883
  }
2856
2884
 
2857
- if (!("toJSON" in source)) {
2885
+ if (!('toJSON' in source)) {
2858
2886
  stack[i] = source;
2859
2887
  const target = isArray(source) ? [] : {};
2860
2888
 
@@ -2875,8 +2903,20 @@ const toJSONObject = (obj) => {
2875
2903
  return visit(obj, 0);
2876
2904
  };
2877
2905
 
2878
- const isAsyncFn = kindOfTest("AsyncFunction");
2906
+ /**
2907
+ * Determines if a value is an async function.
2908
+ *
2909
+ * @param {*} thing - The value to test.
2910
+ * @returns {boolean} True if value is an async function, otherwise false.
2911
+ */
2912
+ const isAsyncFn = kindOfTest('AsyncFunction');
2879
2913
 
2914
+ /**
2915
+ * Determines if a value is thenable (has then and catch methods).
2916
+ *
2917
+ * @param {*} thing - The value to test.
2918
+ * @returns {boolean} True if value is thenable, otherwise false.
2919
+ */
2880
2920
  const isThenable = (thing) =>
2881
2921
  thing &&
2882
2922
  (isObject(thing) || isFunction(thing)) &&
@@ -2886,6 +2926,14 @@ const isThenable = (thing) =>
2886
2926
  // original code
2887
2927
  // https://github.com/DigitalBrainJS/AxiosPromise/blob/16deab13710ec09779922131f3fa5954320f83ab/lib/utils.js#L11-L34
2888
2928
 
2929
+ /**
2930
+ * Provides a cross-platform setImmediate implementation.
2931
+ * Uses native setImmediate if available, otherwise falls back to postMessage or setTimeout.
2932
+ *
2933
+ * @param {boolean} setImmediateSupported - Whether setImmediate is supported.
2934
+ * @param {boolean} postMessageSupported - Whether postMessage is supported.
2935
+ * @returns {Function} A function to schedule a callback asynchronously.
2936
+ */
2889
2937
  const _setImmediate = ((setImmediateSupported, postMessageSupported) => {
2890
2938
  if (setImmediateSupported) {
2891
2939
  return setImmediate;
@@ -2894,27 +2942,33 @@ const _setImmediate = ((setImmediateSupported, postMessageSupported) => {
2894
2942
  return postMessageSupported
2895
2943
  ? ((token, callbacks) => {
2896
2944
  _global.addEventListener(
2897
- "message",
2945
+ 'message',
2898
2946
  ({ source, data }) => {
2899
2947
  if (source === _global && data === token) {
2900
2948
  callbacks.length && callbacks.shift()();
2901
2949
  }
2902
2950
  },
2903
- false,
2951
+ false
2904
2952
  );
2905
2953
 
2906
2954
  return (cb) => {
2907
2955
  callbacks.push(cb);
2908
- _global.postMessage(token, "*");
2956
+ _global.postMessage(token, '*');
2909
2957
  };
2910
2958
  })(`axios@${Math.random()}`, [])
2911
2959
  : (cb) => setTimeout(cb);
2912
- })(typeof setImmediate === "function", isFunction(_global.postMessage));
2960
+ })(typeof setImmediate === 'function', isFunction(_global.postMessage));
2913
2961
 
2962
+ /**
2963
+ * Schedules a microtask or asynchronous callback as soon as possible.
2964
+ * Uses queueMicrotask if available, otherwise falls back to process.nextTick or _setImmediate.
2965
+ *
2966
+ * @type {Function}
2967
+ */
2914
2968
  const asap =
2915
- typeof queueMicrotask !== "undefined"
2969
+ typeof queueMicrotask !== 'undefined'
2916
2970
  ? queueMicrotask.bind(_global)
2917
- : (typeof process !== "undefined" && process.nextTick) || _setImmediate;
2971
+ : (typeof process !== 'undefined' && process.nextTick) || _setImmediate;
2918
2972
 
2919
2973
  // *********************
2920
2974
 
@@ -2939,6 +2993,8 @@ const isIterable = (thing) => thing != null && isFunction(thing[iterator]);
2939
2993
  isUndefined,
2940
2994
  isDate,
2941
2995
  isFile,
2996
+ isReactNativeBlob,
2997
+ isReactNative,
2942
2998
  isBlob,
2943
2999
  isRegExp,
2944
3000
  isFunction,
@@ -2986,57 +3042,74 @@ const isIterable = (thing) => thing != null && isFunction(thing[iterator]);
2986
3042
 
2987
3043
 
2988
3044
  class AxiosError extends Error {
2989
- static from(error, code, config, request, response, customProps) {
2990
- const axiosError = new AxiosError(error.message, code || error.code, config, request, response);
2991
- axiosError.cause = error;
2992
- axiosError.name = error.name;
2993
- customProps && Object.assign(axiosError, customProps);
2994
- return axiosError;
2995
- }
2996
-
2997
- /**
2998
- * Create an Error with the specified message, config, error code, request and response.
2999
- *
3000
- * @param {string} message The error message.
3001
- * @param {string} [code] The error code (for example, 'ECONNABORTED').
3002
- * @param {Object} [config] The config.
3003
- * @param {Object} [request] The request.
3004
- * @param {Object} [response] The response.
3005
- *
3006
- * @returns {Error} The created error.
3007
- */
3008
- constructor(message, code, config, request, response) {
3009
- super(message);
3010
- this.name = 'AxiosError';
3011
- this.isAxiosError = true;
3012
- code && (this.code = code);
3013
- config && (this.config = config);
3014
- request && (this.request = request);
3015
- if (response) {
3016
- this.response = response;
3017
- this.status = response.status;
3018
- }
3045
+ static from(error, code, config, request, response, customProps) {
3046
+ const axiosError = new AxiosError(error.message, code || error.code, config, request, response);
3047
+ axiosError.cause = error;
3048
+ axiosError.name = error.name;
3049
+
3050
+ // Preserve status from the original error if not already set from response
3051
+ if (error.status != null && axiosError.status == null) {
3052
+ axiosError.status = error.status;
3019
3053
  }
3020
3054
 
3021
- toJSON() {
3022
- return {
3023
- // Standard
3024
- message: this.message,
3025
- name: this.name,
3026
- // Microsoft
3027
- description: this.description,
3028
- number: this.number,
3029
- // Mozilla
3030
- fileName: this.fileName,
3031
- lineNumber: this.lineNumber,
3032
- columnNumber: this.columnNumber,
3033
- stack: this.stack,
3034
- // Axios
3035
- config: utils.toJSONObject(this.config),
3036
- code: this.code,
3037
- status: this.status,
3038
- };
3055
+ customProps && Object.assign(axiosError, customProps);
3056
+ return axiosError;
3057
+ }
3058
+
3059
+ /**
3060
+ * Create an Error with the specified message, config, error code, request and response.
3061
+ *
3062
+ * @param {string} message The error message.
3063
+ * @param {string} [code] The error code (for example, 'ECONNABORTED').
3064
+ * @param {Object} [config] The config.
3065
+ * @param {Object} [request] The request.
3066
+ * @param {Object} [response] The response.
3067
+ *
3068
+ * @returns {Error} The created error.
3069
+ */
3070
+ constructor(message, code, config, request, response) {
3071
+ super(message);
3072
+
3073
+ // Make message enumerable to maintain backward compatibility
3074
+ // The native Error constructor sets message as non-enumerable,
3075
+ // but axios < v1.13.3 had it as enumerable
3076
+ Object.defineProperty(this, 'message', {
3077
+ value: message,
3078
+ enumerable: true,
3079
+ writable: true,
3080
+ configurable: true,
3081
+ });
3082
+
3083
+ this.name = 'AxiosError';
3084
+ this.isAxiosError = true;
3085
+ code && (this.code = code);
3086
+ config && (this.config = config);
3087
+ request && (this.request = request);
3088
+ if (response) {
3089
+ this.response = response;
3090
+ this.status = response.status;
3039
3091
  }
3092
+ }
3093
+
3094
+ toJSON() {
3095
+ return {
3096
+ // Standard
3097
+ message: this.message,
3098
+ name: this.name,
3099
+ // Microsoft
3100
+ description: this.description,
3101
+ number: this.number,
3102
+ // Mozilla
3103
+ fileName: this.fileName,
3104
+ lineNumber: this.lineNumber,
3105
+ columnNumber: this.columnNumber,
3106
+ stack: this.stack,
3107
+ // Axios
3108
+ config: utils.toJSONObject(this.config),
3109
+ code: this.code,
3110
+ status: this.status,
3111
+ };
3112
+ }
3040
3113
  }
3041
3114
 
3042
3115
  // This can be changed to static properties as soon as the parser options in .eslint.cjs are updated.
@@ -3052,6 +3125,7 @@ AxiosError.ERR_BAD_REQUEST = 'ERR_BAD_REQUEST';
3052
3125
  AxiosError.ERR_CANCELED = 'ERR_CANCELED';
3053
3126
  AxiosError.ERR_NOT_SUPPORT = 'ERR_NOT_SUPPORT';
3054
3127
  AxiosError.ERR_INVALID_URL = 'ERR_INVALID_URL';
3128
+ AxiosError.ERR_FORM_DATA_DEPTH_EXCEEDED = 'ERR_FORM_DATA_DEPTH_EXCEEDED';
3055
3129
 
3056
3130
  /* harmony default export */ const core_AxiosError = (AxiosError);
3057
3131
 
@@ -3101,11 +3175,14 @@ function removeBrackets(key) {
3101
3175
  */
3102
3176
  function renderKey(path, key, dots) {
3103
3177
  if (!path) return key;
3104
- return path.concat(key).map(function each(token, i) {
3105
- // eslint-disable-next-line no-param-reassign
3106
- token = removeBrackets(token);
3107
- return !dots && i ? '[' + token + ']' : token;
3108
- }).join(dots ? '.' : '');
3178
+ return path
3179
+ .concat(key)
3180
+ .map(function each(token, i) {
3181
+ // eslint-disable-next-line no-param-reassign
3182
+ token = removeBrackets(token);
3183
+ return !dots && i ? '[' + token + ']' : token;
3184
+ })
3185
+ .join(dots ? '.' : '');
3109
3186
  }
3110
3187
 
3111
3188
  /**
@@ -3155,21 +3232,27 @@ function toFormData(obj, formData, options) {
3155
3232
  formData = formData || new (helpers_null || FormData)();
3156
3233
 
3157
3234
  // eslint-disable-next-line no-param-reassign
3158
- options = utils.toFlatObject(options, {
3159
- metaTokens: true,
3160
- dots: false,
3161
- indexes: false
3162
- }, false, function defined(option, source) {
3163
- // eslint-disable-next-line no-eq-null,eqeqeq
3164
- return !utils.isUndefined(source[option]);
3165
- });
3235
+ options = utils.toFlatObject(
3236
+ options,
3237
+ {
3238
+ metaTokens: true,
3239
+ dots: false,
3240
+ indexes: false,
3241
+ },
3242
+ false,
3243
+ function defined(option, source) {
3244
+ // eslint-disable-next-line no-eq-null,eqeqeq
3245
+ return !utils.isUndefined(source[option]);
3246
+ }
3247
+ );
3166
3248
 
3167
3249
  const metaTokens = options.metaTokens;
3168
3250
  // eslint-disable-next-line no-use-before-define
3169
3251
  const visitor = options.visitor || defaultVisitor;
3170
3252
  const dots = options.dots;
3171
3253
  const indexes = options.indexes;
3172
- const _Blob = options.Blob || typeof Blob !== 'undefined' && Blob;
3254
+ const _Blob = options.Blob || (typeof Blob !== 'undefined' && Blob);
3255
+ const maxDepth = options.maxDepth === undefined ? 100 : options.maxDepth;
3173
3256
  const useBlob = _Blob && utils.isSpecCompliantForm(formData);
3174
3257
 
3175
3258
  if (!utils.isFunction(visitor)) {
@@ -3211,6 +3294,11 @@ function toFormData(obj, formData, options) {
3211
3294
  function defaultVisitor(value, key, path) {
3212
3295
  let arr = value;
3213
3296
 
3297
+ if (utils.isReactNative(formData) && utils.isReactNativeBlob(value)) {
3298
+ formData.append(renderKey(path, key, dots), convertValue(value));
3299
+ return false;
3300
+ }
3301
+
3214
3302
  if (value && !path && typeof value === 'object') {
3215
3303
  if (utils.endsWith(key, '{}')) {
3216
3304
  // eslint-disable-next-line no-param-reassign
@@ -3219,17 +3307,22 @@ function toFormData(obj, formData, options) {
3219
3307
  value = JSON.stringify(value);
3220
3308
  } else if (
3221
3309
  (utils.isArray(value) && isFlatArray(value)) ||
3222
- ((utils.isFileList(value) || utils.endsWith(key, '[]')) && (arr = utils.toArray(value))
3223
- )) {
3310
+ ((utils.isFileList(value) || utils.endsWith(key, '[]')) && (arr = utils.toArray(value)))
3311
+ ) {
3224
3312
  // eslint-disable-next-line no-param-reassign
3225
3313
  key = removeBrackets(key);
3226
3314
 
3227
3315
  arr.forEach(function each(el, index) {
3228
- !(utils.isUndefined(el) || el === null) && formData.append(
3229
- // eslint-disable-next-line no-nested-ternary
3230
- indexes === true ? renderKey([key], index, dots) : (indexes === null ? key : key + '[]'),
3231
- convertValue(el)
3232
- );
3316
+ !(utils.isUndefined(el) || el === null) &&
3317
+ formData.append(
3318
+ // eslint-disable-next-line no-nested-ternary
3319
+ indexes === true
3320
+ ? renderKey([key], index, dots)
3321
+ : indexes === null
3322
+ ? key
3323
+ : key + '[]',
3324
+ convertValue(el)
3325
+ );
3233
3326
  });
3234
3327
  return false;
3235
3328
  }
@@ -3249,12 +3342,19 @@ function toFormData(obj, formData, options) {
3249
3342
  const exposedHelpers = Object.assign(predicates, {
3250
3343
  defaultVisitor,
3251
3344
  convertValue,
3252
- isVisitable
3345
+ isVisitable,
3253
3346
  });
3254
3347
 
3255
- function build(value, path) {
3348
+ function build(value, path, depth = 0) {
3256
3349
  if (utils.isUndefined(value)) return;
3257
3350
 
3351
+ if (depth > maxDepth) {
3352
+ throw new core_AxiosError(
3353
+ 'Object is too deeply nested (' + depth + ' levels). Max depth: ' + maxDepth,
3354
+ core_AxiosError.ERR_FORM_DATA_DEPTH_EXCEEDED
3355
+ );
3356
+ }
3357
+
3258
3358
  if (stack.indexOf(value) !== -1) {
3259
3359
  throw Error('Circular reference detected in ' + path.join('.'));
3260
3360
  }
@@ -3262,12 +3362,12 @@ function toFormData(obj, formData, options) {
3262
3362
  stack.push(value);
3263
3363
 
3264
3364
  utils.forEach(value, function each(el, key) {
3265
- const result = !(utils.isUndefined(el) || el === null) && visitor.call(
3266
- formData, el, utils.isString(key) ? key.trim() : key, path, exposedHelpers
3267
- );
3365
+ const result =
3366
+ !(utils.isUndefined(el) || el === null) &&
3367
+ visitor.call(formData, el, utils.isString(key) ? key.trim() : key, path, exposedHelpers);
3268
3368
 
3269
3369
  if (result === true) {
3270
- build(el, path ? path.concat(key) : [key]);
3370
+ build(el, path ? path.concat(key) : [key], depth + 1);
3271
3371
  }
3272
3372
  });
3273
3373
 
@@ -3306,9 +3406,8 @@ function encode(str) {
3306
3406
  ')': '%29',
3307
3407
  '~': '%7E',
3308
3408
  '%20': '+',
3309
- '%00': '\x00'
3310
3409
  };
3311
- return encodeURIComponent(str).replace(/[!'()~]|%20|%00/g, function replacer(match) {
3410
+ return encodeURIComponent(str).replace(/[!'()~]|%20/g, function replacer(match) {
3312
3411
  return charMap[match];
3313
3412
  });
3314
3413
  }
@@ -3334,13 +3433,17 @@ AxiosURLSearchParams_prototype.append = function append(name, value) {
3334
3433
  };
3335
3434
 
3336
3435
  AxiosURLSearchParams_prototype.toString = function toString(encoder) {
3337
- const _encode = encoder ? function(value) {
3338
- return encoder.call(this, value, encode);
3339
- } : encode;
3436
+ const _encode = encoder
3437
+ ? function (value) {
3438
+ return encoder.call(this, value, encode);
3439
+ }
3440
+ : encode;
3340
3441
 
3341
- return this._pairs.map(function each(pair) {
3342
- return _encode(pair[0]) + '=' + _encode(pair[1]);
3343
- }, '').join('&');
3442
+ return this._pairs
3443
+ .map(function each(pair) {
3444
+ return _encode(pair[0]) + '=' + _encode(pair[1]);
3445
+ }, '')
3446
+ .join('&');
3344
3447
  };
3345
3448
 
3346
3449
  /* harmony default export */ const helpers_AxiosURLSearchParams = (AxiosURLSearchParams);
@@ -3352,19 +3455,19 @@ AxiosURLSearchParams_prototype.toString = function toString(encoder) {
3352
3455
 
3353
3456
 
3354
3457
  /**
3355
- * It replaces all instances of the characters `:`, `$`, `,`, `+`, `[`, and `]` with their
3356
- * URI encoded counterparts
3458
+ * It replaces URL-encoded forms of `:`, `$`, `,`, and spaces with
3459
+ * their plain counterparts (`:`, `$`, `,`, `+`).
3357
3460
  *
3358
3461
  * @param {string} val The value to be encoded.
3359
3462
  *
3360
3463
  * @returns {string} The encoded value.
3361
3464
  */
3362
3465
  function buildURL_encode(val) {
3363
- return encodeURIComponent(val).
3364
- replace(/%3A/gi, ':').
3365
- replace(/%24/g, '$').
3366
- replace(/%2C/gi, ',').
3367
- replace(/%20/g, '+');
3466
+ return encodeURIComponent(val)
3467
+ .replace(/%3A/gi, ':')
3468
+ .replace(/%24/g, '$')
3469
+ .replace(/%2C/gi, ',')
3470
+ .replace(/%20/g, '+');
3368
3471
  }
3369
3472
 
3370
3473
  /**
@@ -3381,11 +3484,13 @@ function buildURL(url, params, options) {
3381
3484
  return url;
3382
3485
  }
3383
3486
 
3384
- const _encode = options && options.encode || buildURL_encode;
3487
+ const _encode = (options && options.encode) || buildURL_encode;
3385
3488
 
3386
- const _options = utils.isFunction(options) ? {
3387
- serialize: options
3388
- } : options;
3489
+ const _options = utils.isFunction(options)
3490
+ ? {
3491
+ serialize: options,
3492
+ }
3493
+ : options;
3389
3494
 
3390
3495
  const serializeFn = _options && _options.serialize;
3391
3496
 
@@ -3394,13 +3499,13 @@ function buildURL(url, params, options) {
3394
3499
  if (serializeFn) {
3395
3500
  serializedParams = serializeFn(params, _options);
3396
3501
  } else {
3397
- serializedParams = utils.isURLSearchParams(params) ?
3398
- params.toString() :
3399
- new helpers_AxiosURLSearchParams(params, _options).toString(_encode);
3502
+ serializedParams = utils.isURLSearchParams(params)
3503
+ ? params.toString()
3504
+ : new helpers_AxiosURLSearchParams(params, _options).toString(_encode);
3400
3505
  }
3401
3506
 
3402
3507
  if (serializedParams) {
3403
- const hashmarkIndex = url.indexOf("#");
3508
+ const hashmarkIndex = url.indexOf('#');
3404
3509
 
3405
3510
  if (hashmarkIndex !== -1) {
3406
3511
  url = url.slice(0, hashmarkIndex);
@@ -3435,7 +3540,7 @@ class InterceptorManager {
3435
3540
  fulfilled,
3436
3541
  rejected,
3437
3542
  synchronous: options ? options.synchronous : false,
3438
- runWhen: options ? options.runWhen : null
3543
+ runWhen: options ? options.runWhen : null,
3439
3544
  });
3440
3545
  return this.handlers.length - 1;
3441
3546
  }
@@ -3492,7 +3597,7 @@ class InterceptorManager {
3492
3597
  silentJSONParsing: true,
3493
3598
  forcedJSONParsing: true,
3494
3599
  clarifyTimeoutError: false,
3495
- legacyInterceptorReqResOrdering: true
3600
+ legacyInterceptorReqResOrdering: true,
3496
3601
  });
3497
3602
 
3498
3603
  ;// ../../../node_modules/axios/lib/platform/browser/classes/URLSearchParams.js
@@ -3521,15 +3626,15 @@ class InterceptorManager {
3521
3626
  classes: {
3522
3627
  URLSearchParams: classes_URLSearchParams,
3523
3628
  FormData: classes_FormData,
3524
- Blob: classes_Blob
3629
+ Blob: classes_Blob,
3525
3630
  },
3526
- protocols: ['http', 'https', 'file', 'blob', 'url', 'data']
3631
+ protocols: ['http', 'https', 'file', 'blob', 'url', 'data'],
3527
3632
  });
3528
3633
 
3529
3634
  ;// ../../../node_modules/axios/lib/platform/common/utils.js
3530
3635
  const hasBrowserEnv = typeof window !== 'undefined' && typeof document !== 'undefined';
3531
3636
 
3532
- const _navigator = typeof navigator === 'object' && navigator || undefined;
3637
+ const _navigator = (typeof navigator === 'object' && navigator) || undefined;
3533
3638
 
3534
3639
  /**
3535
3640
  * Determine if we're running in a standard browser environment
@@ -3548,7 +3653,8 @@ const _navigator = typeof navigator === 'object' && navigator || undefined;
3548
3653
  *
3549
3654
  * @returns {boolean}
3550
3655
  */
3551
- const hasStandardBrowserEnv = hasBrowserEnv &&
3656
+ const hasStandardBrowserEnv =
3657
+ hasBrowserEnv &&
3552
3658
  (!_navigator || ['ReactNative', 'NativeScript', 'NS'].indexOf(_navigator.product) < 0);
3553
3659
 
3554
3660
  /**
@@ -3569,7 +3675,7 @@ const hasStandardBrowserWebWorkerEnv = (() => {
3569
3675
  );
3570
3676
  })();
3571
3677
 
3572
- const origin = hasBrowserEnv && window.location.href || 'http://localhost';
3678
+ const origin = (hasBrowserEnv && window.location.href) || 'http://localhost';
3573
3679
 
3574
3680
 
3575
3681
 
@@ -3579,7 +3685,7 @@ const origin = hasBrowserEnv && window.location.href || 'http://localhost';
3579
3685
 
3580
3686
  /* harmony default export */ const platform = ({
3581
3687
  ...common_utils_namespaceObject,
3582
- ...browser
3688
+ ...browser,
3583
3689
  });
3584
3690
 
3585
3691
  ;// ../../../node_modules/axios/lib/helpers/toURLEncodedForm.js
@@ -3591,7 +3697,7 @@ const origin = hasBrowserEnv && window.location.href || 'http://localhost';
3591
3697
 
3592
3698
  function toURLEncodedForm(data, options) {
3593
3699
  return helpers_toFormData(data, new platform.classes.URLSearchParams(), {
3594
- visitor: function(value, key, path, helpers) {
3700
+ visitor: function (value, key, path, helpers) {
3595
3701
  if (platform.isNode && utils.isBuffer(value)) {
3596
3702
  this.append(key, value.toString('base64'));
3597
3703
  return false;
@@ -3599,7 +3705,7 @@ function toURLEncodedForm(data, options) {
3599
3705
 
3600
3706
  return helpers.defaultVisitor.apply(this, arguments);
3601
3707
  },
3602
- ...options
3708
+ ...options,
3603
3709
  });
3604
3710
  }
3605
3711
 
@@ -3620,7 +3726,7 @@ function parsePropPath(name) {
3620
3726
  // foo.x.y.z
3621
3727
  // foo-x-y-z
3622
3728
  // foo x y z
3623
- return utils.matchAll(/\w+|\[(\w*)]/g, name).map(match => {
3729
+ return utils.matchAll(/\w+|\[(\w*)]/g, name).map((match) => {
3624
3730
  return match[0] === '[]' ? '' : match[1] || match[0];
3625
3731
  });
3626
3732
  }
@@ -3664,7 +3770,9 @@ function formDataToJSON(formData) {
3664
3770
 
3665
3771
  if (isLast) {
3666
3772
  if (utils.hasOwnProp(target, name)) {
3667
- target[name] = [target[name], value];
3773
+ target[name] = utils.isArray(target[name])
3774
+ ? target[name].concat(value)
3775
+ : [target[name], value];
3668
3776
  } else {
3669
3777
  target[name] = value;
3670
3778
  }
@@ -3711,6 +3819,8 @@ function formDataToJSON(formData) {
3711
3819
 
3712
3820
 
3713
3821
 
3822
+ const own = (obj, key) => (obj != null && utils.hasOwnProp(obj, key) ? obj[key] : undefined);
3823
+
3714
3824
  /**
3715
3825
  * It takes a string, tries to parse it, and if it fails, it returns the stringified version
3716
3826
  * of the input
@@ -3737,96 +3847,110 @@ function stringifySafely(rawValue, parser, encoder) {
3737
3847
  }
3738
3848
 
3739
3849
  const defaults = {
3740
-
3741
3850
  transitional: defaults_transitional,
3742
3851
 
3743
3852
  adapter: ['xhr', 'http', 'fetch'],
3744
3853
 
3745
- transformRequest: [function transformRequest(data, headers) {
3746
- const contentType = headers.getContentType() || '';
3747
- const hasJSONContentType = contentType.indexOf('application/json') > -1;
3748
- const isObjectPayload = utils.isObject(data);
3749
-
3750
- if (isObjectPayload && utils.isHTMLForm(data)) {
3751
- data = new FormData(data);
3752
- }
3753
-
3754
- const isFormData = utils.isFormData(data);
3854
+ transformRequest: [
3855
+ function transformRequest(data, headers) {
3856
+ const contentType = headers.getContentType() || '';
3857
+ const hasJSONContentType = contentType.indexOf('application/json') > -1;
3858
+ const isObjectPayload = utils.isObject(data);
3755
3859
 
3756
- if (isFormData) {
3757
- return hasJSONContentType ? JSON.stringify(helpers_formDataToJSON(data)) : data;
3758
- }
3860
+ if (isObjectPayload && utils.isHTMLForm(data)) {
3861
+ data = new FormData(data);
3862
+ }
3759
3863
 
3760
- if (utils.isArrayBuffer(data) ||
3761
- utils.isBuffer(data) ||
3762
- utils.isStream(data) ||
3763
- utils.isFile(data) ||
3764
- utils.isBlob(data) ||
3765
- utils.isReadableStream(data)
3766
- ) {
3767
- return data;
3768
- }
3769
- if (utils.isArrayBufferView(data)) {
3770
- return data.buffer;
3771
- }
3772
- if (utils.isURLSearchParams(data)) {
3773
- headers.setContentType('application/x-www-form-urlencoded;charset=utf-8', false);
3774
- return data.toString();
3775
- }
3864
+ const isFormData = utils.isFormData(data);
3776
3865
 
3777
- let isFileList;
3866
+ if (isFormData) {
3867
+ return hasJSONContentType ? JSON.stringify(helpers_formDataToJSON(data)) : data;
3868
+ }
3778
3869
 
3779
- if (isObjectPayload) {
3780
- if (contentType.indexOf('application/x-www-form-urlencoded') > -1) {
3781
- return toURLEncodedForm(data, this.formSerializer).toString();
3870
+ if (
3871
+ utils.isArrayBuffer(data) ||
3872
+ utils.isBuffer(data) ||
3873
+ utils.isStream(data) ||
3874
+ utils.isFile(data) ||
3875
+ utils.isBlob(data) ||
3876
+ utils.isReadableStream(data)
3877
+ ) {
3878
+ return data;
3879
+ }
3880
+ if (utils.isArrayBufferView(data)) {
3881
+ return data.buffer;
3882
+ }
3883
+ if (utils.isURLSearchParams(data)) {
3884
+ headers.setContentType('application/x-www-form-urlencoded;charset=utf-8', false);
3885
+ return data.toString();
3782
3886
  }
3783
3887
 
3784
- if ((isFileList = utils.isFileList(data)) || contentType.indexOf('multipart/form-data') > -1) {
3785
- const _FormData = this.env && this.env.FormData;
3888
+ let isFileList;
3786
3889
 
3787
- return helpers_toFormData(
3788
- isFileList ? {'files[]': data} : data,
3789
- _FormData && new _FormData(),
3790
- this.formSerializer
3791
- );
3890
+ if (isObjectPayload) {
3891
+ const formSerializer = own(this, 'formSerializer');
3892
+ if (contentType.indexOf('application/x-www-form-urlencoded') > -1) {
3893
+ return toURLEncodedForm(data, formSerializer).toString();
3894
+ }
3895
+
3896
+ if (
3897
+ (isFileList = utils.isFileList(data)) ||
3898
+ contentType.indexOf('multipart/form-data') > -1
3899
+ ) {
3900
+ const env = own(this, 'env');
3901
+ const _FormData = env && env.FormData;
3902
+
3903
+ return helpers_toFormData(
3904
+ isFileList ? { 'files[]': data } : data,
3905
+ _FormData && new _FormData(),
3906
+ formSerializer
3907
+ );
3908
+ }
3792
3909
  }
3793
- }
3794
3910
 
3795
- if (isObjectPayload || hasJSONContentType ) {
3796
- headers.setContentType('application/json', false);
3797
- return stringifySafely(data);
3798
- }
3911
+ if (isObjectPayload || hasJSONContentType) {
3912
+ headers.setContentType('application/json', false);
3913
+ return stringifySafely(data);
3914
+ }
3799
3915
 
3800
- return data;
3801
- }],
3916
+ return data;
3917
+ },
3918
+ ],
3802
3919
 
3803
- transformResponse: [function transformResponse(data) {
3804
- const transitional = this.transitional || defaults.transitional;
3805
- const forcedJSONParsing = transitional && transitional.forcedJSONParsing;
3806
- const JSONRequested = this.responseType === 'json';
3920
+ transformResponse: [
3921
+ function transformResponse(data) {
3922
+ const transitional = own(this, 'transitional') || defaults.transitional;
3923
+ const forcedJSONParsing = transitional && transitional.forcedJSONParsing;
3924
+ const responseType = own(this, 'responseType');
3925
+ const JSONRequested = responseType === 'json';
3807
3926
 
3808
- if (utils.isResponse(data) || utils.isReadableStream(data)) {
3809
- return data;
3810
- }
3927
+ if (utils.isResponse(data) || utils.isReadableStream(data)) {
3928
+ return data;
3929
+ }
3811
3930
 
3812
- if (data && utils.isString(data) && ((forcedJSONParsing && !this.responseType) || JSONRequested)) {
3813
- const silentJSONParsing = transitional && transitional.silentJSONParsing;
3814
- const strictJSONParsing = !silentJSONParsing && JSONRequested;
3931
+ if (
3932
+ data &&
3933
+ utils.isString(data) &&
3934
+ ((forcedJSONParsing && !responseType) || JSONRequested)
3935
+ ) {
3936
+ const silentJSONParsing = transitional && transitional.silentJSONParsing;
3937
+ const strictJSONParsing = !silentJSONParsing && JSONRequested;
3815
3938
 
3816
- try {
3817
- return JSON.parse(data, this.parseReviver);
3818
- } catch (e) {
3819
- if (strictJSONParsing) {
3820
- if (e.name === 'SyntaxError') {
3821
- throw core_AxiosError.from(e, core_AxiosError.ERR_BAD_RESPONSE, this, null, this.response);
3939
+ try {
3940
+ return JSON.parse(data, own(this, 'parseReviver'));
3941
+ } catch (e) {
3942
+ if (strictJSONParsing) {
3943
+ if (e.name === 'SyntaxError') {
3944
+ throw core_AxiosError.from(e, core_AxiosError.ERR_BAD_RESPONSE, this, null, own(this, 'response'));
3945
+ }
3946
+ throw e;
3822
3947
  }
3823
- throw e;
3824
3948
  }
3825
3949
  }
3826
- }
3827
3950
 
3828
- return data;
3829
- }],
3951
+ return data;
3952
+ },
3953
+ ],
3830
3954
 
3831
3955
  /**
3832
3956
  * A timeout in milliseconds to abort a request. If set to 0 (default) a
@@ -3842,7 +3966,7 @@ const defaults = {
3842
3966
 
3843
3967
  env: {
3844
3968
  FormData: platform.classes.FormData,
3845
- Blob: platform.classes.Blob
3969
+ Blob: platform.classes.Blob,
3846
3970
  },
3847
3971
 
3848
3972
  validateStatus: function validateStatus(status) {
@@ -3851,10 +3975,10 @@ const defaults = {
3851
3975
 
3852
3976
  headers: {
3853
3977
  common: {
3854
- 'Accept': 'application/json, text/plain, */*',
3855
- 'Content-Type': undefined
3856
- }
3857
- }
3978
+ Accept: 'application/json, text/plain, */*',
3979
+ 'Content-Type': undefined,
3980
+ },
3981
+ },
3858
3982
  };
3859
3983
 
3860
3984
  utils.forEach(['delete', 'get', 'head', 'post', 'put', 'patch'], (method) => {
@@ -3871,10 +3995,23 @@ utils.forEach(['delete', 'get', 'head', 'post', 'put', 'patch'], (method) => {
3871
3995
  // RawAxiosHeaders whose duplicates are ignored by node
3872
3996
  // c.f. https://nodejs.org/api/http.html#http_message_headers
3873
3997
  const ignoreDuplicateOf = utils.toObjectSet([
3874
- 'age', 'authorization', 'content-length', 'content-type', 'etag',
3875
- 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since',
3876
- 'last-modified', 'location', 'max-forwards', 'proxy-authorization',
3877
- 'referer', 'retry-after', 'user-agent'
3998
+ 'age',
3999
+ 'authorization',
4000
+ 'content-length',
4001
+ 'content-type',
4002
+ 'etag',
4003
+ 'expires',
4004
+ 'from',
4005
+ 'host',
4006
+ 'if-modified-since',
4007
+ 'if-unmodified-since',
4008
+ 'last-modified',
4009
+ 'location',
4010
+ 'max-forwards',
4011
+ 'proxy-authorization',
4012
+ 'referer',
4013
+ 'retry-after',
4014
+ 'user-agent',
3878
4015
  ]);
3879
4016
 
3880
4017
  /**
@@ -3891,31 +4028,32 @@ const ignoreDuplicateOf = utils.toObjectSet([
3891
4028
  *
3892
4029
  * @returns {Object} Headers parsed into an object
3893
4030
  */
3894
- /* harmony default export */ const parseHeaders = (rawHeaders => {
4031
+ /* harmony default export */ const parseHeaders = ((rawHeaders) => {
3895
4032
  const parsed = {};
3896
4033
  let key;
3897
4034
  let val;
3898
4035
  let i;
3899
4036
 
3900
- rawHeaders && rawHeaders.split('\n').forEach(function parser(line) {
3901
- i = line.indexOf(':');
3902
- key = line.substring(0, i).trim().toLowerCase();
3903
- val = line.substring(i + 1).trim();
4037
+ rawHeaders &&
4038
+ rawHeaders.split('\n').forEach(function parser(line) {
4039
+ i = line.indexOf(':');
4040
+ key = line.substring(0, i).trim().toLowerCase();
4041
+ val = line.substring(i + 1).trim();
3904
4042
 
3905
- if (!key || (parsed[key] && ignoreDuplicateOf[key])) {
3906
- return;
3907
- }
4043
+ if (!key || (parsed[key] && ignoreDuplicateOf[key])) {
4044
+ return;
4045
+ }
3908
4046
 
3909
- if (key === 'set-cookie') {
3910
- if (parsed[key]) {
3911
- parsed[key].push(val);
4047
+ if (key === 'set-cookie') {
4048
+ if (parsed[key]) {
4049
+ parsed[key].push(val);
4050
+ } else {
4051
+ parsed[key] = [val];
4052
+ }
3912
4053
  } else {
3913
- parsed[key] = [val];
4054
+ parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;
3914
4055
  }
3915
- } else {
3916
- parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;
3917
- }
3918
- });
4056
+ });
3919
4057
 
3920
4058
  return parsed;
3921
4059
  });
@@ -3928,16 +4066,49 @@ const ignoreDuplicateOf = utils.toObjectSet([
3928
4066
 
3929
4067
  const $internals = Symbol('internals');
3930
4068
 
4069
+ const INVALID_HEADER_VALUE_CHARS_RE = /[^\x09\x20-\x7E\x80-\xFF]/g;
4070
+
4071
+ function trimSPorHTAB(str) {
4072
+ let start = 0;
4073
+ let end = str.length;
4074
+
4075
+ while (start < end) {
4076
+ const code = str.charCodeAt(start);
4077
+
4078
+ if (code !== 0x09 && code !== 0x20) {
4079
+ break;
4080
+ }
4081
+
4082
+ start += 1;
4083
+ }
4084
+
4085
+ while (end > start) {
4086
+ const code = str.charCodeAt(end - 1);
4087
+
4088
+ if (code !== 0x09 && code !== 0x20) {
4089
+ break;
4090
+ }
4091
+
4092
+ end -= 1;
4093
+ }
4094
+
4095
+ return start === 0 && end === str.length ? str : str.slice(start, end);
4096
+ }
4097
+
3931
4098
  function normalizeHeader(header) {
3932
4099
  return header && String(header).trim().toLowerCase();
3933
4100
  }
3934
4101
 
4102
+ function sanitizeHeaderValue(str) {
4103
+ return trimSPorHTAB(str.replace(INVALID_HEADER_VALUE_CHARS_RE, ''));
4104
+ }
4105
+
3935
4106
  function normalizeValue(value) {
3936
4107
  if (value === false || value == null) {
3937
4108
  return value;
3938
4109
  }
3939
4110
 
3940
- return utils.isArray(value) ? value.map(normalizeValue) : String(value);
4111
+ return utils.isArray(value) ? value.map(normalizeValue) : sanitizeHeaderValue(String(value));
3941
4112
  }
3942
4113
 
3943
4114
  function parseTokens(str) {
@@ -3975,8 +4146,10 @@ function matchHeaderValue(context, value, header, filter, isHeaderNameFilter) {
3975
4146
  }
3976
4147
 
3977
4148
  function formatHeader(header) {
3978
- return header.trim()
3979
- .toLowerCase().replace(/([a-z\d])(\w*)/g, (w, char, str) => {
4149
+ return header
4150
+ .trim()
4151
+ .toLowerCase()
4152
+ .replace(/([a-z\d])(\w*)/g, (w, char, str) => {
3980
4153
  return char.toUpperCase() + str;
3981
4154
  });
3982
4155
  }
@@ -3984,12 +4157,12 @@ function formatHeader(header) {
3984
4157
  function buildAccessors(obj, header) {
3985
4158
  const accessorName = utils.toCamelCase(' ' + header);
3986
4159
 
3987
- ['get', 'set', 'has'].forEach(methodName => {
4160
+ ['get', 'set', 'has'].forEach((methodName) => {
3988
4161
  Object.defineProperty(obj, methodName + accessorName, {
3989
- value: function(arg1, arg2, arg3) {
4162
+ value: function (arg1, arg2, arg3) {
3990
4163
  return this[methodName].call(this, header, arg1, arg2, arg3);
3991
4164
  },
3992
- configurable: true
4165
+ configurable: true,
3993
4166
  });
3994
4167
  });
3995
4168
  }
@@ -4011,7 +4184,12 @@ class AxiosHeaders {
4011
4184
 
4012
4185
  const key = utils.findKey(self, lHeader);
4013
4186
 
4014
- if(!key || self[key] === undefined || _rewrite === true || (_rewrite === undefined && self[key] !== false)) {
4187
+ if (
4188
+ !key ||
4189
+ self[key] === undefined ||
4190
+ _rewrite === true ||
4191
+ (_rewrite === undefined && self[key] !== false)
4192
+ ) {
4015
4193
  self[key || _header] = normalizeValue(_value);
4016
4194
  }
4017
4195
  }
@@ -4020,21 +4198,26 @@ class AxiosHeaders {
4020
4198
  utils.forEach(headers, (_value, _header) => setHeader(_value, _header, _rewrite));
4021
4199
 
4022
4200
  if (utils.isPlainObject(header) || header instanceof this.constructor) {
4023
- setHeaders(header, valueOrRewrite)
4024
- } else if(utils.isString(header) && (header = header.trim()) && !isValidHeaderName(header)) {
4201
+ setHeaders(header, valueOrRewrite);
4202
+ } else if (utils.isString(header) && (header = header.trim()) && !isValidHeaderName(header)) {
4025
4203
  setHeaders(parseHeaders(header), valueOrRewrite);
4026
4204
  } else if (utils.isObject(header) && utils.isIterable(header)) {
4027
- let obj = {}, dest, key;
4205
+ let obj = {},
4206
+ dest,
4207
+ key;
4028
4208
  for (const entry of header) {
4029
4209
  if (!utils.isArray(entry)) {
4030
4210
  throw TypeError('Object iterator must return a key-value pair');
4031
4211
  }
4032
4212
 
4033
- obj[key = entry[0]] = (dest = obj[key]) ?
4034
- (utils.isArray(dest) ? [...dest, entry[1]] : [dest, entry[1]]) : entry[1];
4213
+ obj[(key = entry[0])] = (dest = obj[key])
4214
+ ? utils.isArray(dest)
4215
+ ? [...dest, entry[1]]
4216
+ : [dest, entry[1]]
4217
+ : entry[1];
4035
4218
  }
4036
4219
 
4037
- setHeaders(obj, valueOrRewrite)
4220
+ setHeaders(obj, valueOrRewrite);
4038
4221
  } else {
4039
4222
  header != null && setHeader(valueOrRewrite, header, rewrite);
4040
4223
  }
@@ -4078,7 +4261,11 @@ class AxiosHeaders {
4078
4261
  if (header) {
4079
4262
  const key = utils.findKey(this, header);
4080
4263
 
4081
- return !!(key && this[key] !== undefined && (!matcher || matchHeaderValue(this, this[key], key, matcher)));
4264
+ return !!(
4265
+ key &&
4266
+ this[key] !== undefined &&
4267
+ (!matcher || matchHeaderValue(this, this[key], key, matcher))
4268
+ );
4082
4269
  }
4083
4270
 
4084
4271
  return false;
@@ -4118,7 +4305,7 @@ class AxiosHeaders {
4118
4305
 
4119
4306
  while (i--) {
4120
4307
  const key = keys[i];
4121
- if(!matcher || matchHeaderValue(this, this[key], key, matcher, true)) {
4308
+ if (!matcher || matchHeaderValue(this, this[key], key, matcher, true)) {
4122
4309
  delete this[key];
4123
4310
  deleted = true;
4124
4311
  }
@@ -4162,7 +4349,9 @@ class AxiosHeaders {
4162
4349
  const obj = Object.create(null);
4163
4350
 
4164
4351
  utils.forEach(this, (value, header) => {
4165
- value != null && value !== false && (obj[header] = asStrings && utils.isArray(value) ? value.join(', ') : value);
4352
+ value != null &&
4353
+ value !== false &&
4354
+ (obj[header] = asStrings && utils.isArray(value) ? value.join(', ') : value);
4166
4355
  });
4167
4356
 
4168
4357
  return obj;
@@ -4173,11 +4362,13 @@ class AxiosHeaders {
4173
4362
  }
4174
4363
 
4175
4364
  toString() {
4176
- return Object.entries(this.toJSON()).map(([header, value]) => header + ': ' + value).join('\n');
4365
+ return Object.entries(this.toJSON())
4366
+ .map(([header, value]) => header + ': ' + value)
4367
+ .join('\n');
4177
4368
  }
4178
4369
 
4179
4370
  getSetCookie() {
4180
- return this.get("set-cookie") || [];
4371
+ return this.get('set-cookie') || [];
4181
4372
  }
4182
4373
 
4183
4374
  get [Symbol.toStringTag]() {
@@ -4197,9 +4388,12 @@ class AxiosHeaders {
4197
4388
  }
4198
4389
 
4199
4390
  static accessor(header) {
4200
- const internals = this[$internals] = (this[$internals] = {
4201
- accessors: {}
4202
- });
4391
+ const internals =
4392
+ (this[$internals] =
4393
+ this[$internals] =
4394
+ {
4395
+ accessors: {},
4396
+ });
4203
4397
 
4204
4398
  const accessors = internals.accessors;
4205
4399
  const prototype = this.prototype;
@@ -4219,17 +4413,24 @@ class AxiosHeaders {
4219
4413
  }
4220
4414
  }
4221
4415
 
4222
- AxiosHeaders.accessor(['Content-Type', 'Content-Length', 'Accept', 'Accept-Encoding', 'User-Agent', 'Authorization']);
4416
+ AxiosHeaders.accessor([
4417
+ 'Content-Type',
4418
+ 'Content-Length',
4419
+ 'Accept',
4420
+ 'Accept-Encoding',
4421
+ 'User-Agent',
4422
+ 'Authorization',
4423
+ ]);
4223
4424
 
4224
4425
  // reserved names hotfix
4225
- utils.reduceDescriptors(AxiosHeaders.prototype, ({value}, key) => {
4426
+ utils.reduceDescriptors(AxiosHeaders.prototype, ({ value }, key) => {
4226
4427
  let mapped = key[0].toUpperCase() + key.slice(1); // map `set` => `Set`
4227
4428
  return {
4228
4429
  get: () => value,
4229
4430
  set(headerValue) {
4230
4431
  this[mapped] = headerValue;
4231
- }
4232
- }
4432
+ },
4433
+ };
4233
4434
  });
4234
4435
 
4235
4436
  utils.freezeMethods(AxiosHeaders);
@@ -4316,13 +4517,17 @@ function settle(resolve, reject, response) {
4316
4517
  if (!response.status || !validateStatus || validateStatus(response.status)) {
4317
4518
  resolve(response);
4318
4519
  } else {
4319
- reject(new core_AxiosError(
4320
- 'Request failed with status code ' + response.status,
4321
- [core_AxiosError.ERR_BAD_REQUEST, core_AxiosError.ERR_BAD_RESPONSE][Math.floor(response.status / 100) - 4],
4322
- response.config,
4323
- response.request,
4324
- response
4325
- ));
4520
+ reject(
4521
+ new core_AxiosError(
4522
+ 'Request failed with status code ' + response.status,
4523
+ [core_AxiosError.ERR_BAD_REQUEST, core_AxiosError.ERR_BAD_RESPONSE][
4524
+ Math.floor(response.status / 100) - 4
4525
+ ],
4526
+ response.config,
4527
+ response.request,
4528
+ response
4529
+ )
4530
+ );
4326
4531
  }
4327
4532
  }
4328
4533
 
@@ -4331,7 +4536,7 @@ function settle(resolve, reject, response) {
4331
4536
 
4332
4537
  function parseProtocol(url) {
4333
4538
  const match = /^([-+\w]{1,25})(:?\/\/|:)/.exec(url);
4334
- return match && match[1] || '';
4539
+ return (match && match[1]) || '';
4335
4540
  }
4336
4541
 
4337
4542
  ;// ../../../node_modules/axios/lib/helpers/speedometer.js
@@ -4385,7 +4590,7 @@ function speedometer(samplesCount, min) {
4385
4590
 
4386
4591
  const passed = startedAt && now - startedAt;
4387
4592
 
4388
- return passed ? Math.round(bytesCount * 1000 / passed) : undefined;
4593
+ return passed ? Math.round((bytesCount * 1000) / passed) : undefined;
4389
4594
  };
4390
4595
  }
4391
4596
 
@@ -4412,23 +4617,23 @@ function throttle(fn, freq) {
4412
4617
  timer = null;
4413
4618
  }
4414
4619
  fn(...args);
4415
- }
4620
+ };
4416
4621
 
4417
4622
  const throttled = (...args) => {
4418
4623
  const now = Date.now();
4419
4624
  const passed = now - timestamp;
4420
- if ( passed >= threshold) {
4625
+ if (passed >= threshold) {
4421
4626
  invoke(args, now);
4422
4627
  } else {
4423
4628
  lastArgs = args;
4424
4629
  if (!timer) {
4425
4630
  timer = setTimeout(() => {
4426
4631
  timer = null;
4427
- invoke(lastArgs)
4632
+ invoke(lastArgs);
4428
4633
  }, threshold - passed);
4429
4634
  }
4430
4635
  }
4431
- }
4636
+ };
4432
4637
 
4433
4638
  const flush = () => lastArgs && invoke(lastArgs);
4434
4639
 
@@ -4446,113 +4651,117 @@ const progressEventReducer = (listener, isDownloadStream, freq = 3) => {
4446
4651
  let bytesNotified = 0;
4447
4652
  const _speedometer = helpers_speedometer(50, 250);
4448
4653
 
4449
- return helpers_throttle(e => {
4450
- const loaded = e.loaded;
4654
+ return helpers_throttle((e) => {
4655
+ const rawLoaded = e.loaded;
4451
4656
  const total = e.lengthComputable ? e.total : undefined;
4452
- const progressBytes = loaded - bytesNotified;
4657
+ const loaded = total != null ? Math.min(rawLoaded, total) : rawLoaded;
4658
+ const progressBytes = Math.max(0, loaded - bytesNotified);
4453
4659
  const rate = _speedometer(progressBytes);
4454
- const inRange = loaded <= total;
4455
4660
 
4456
- bytesNotified = loaded;
4661
+ bytesNotified = Math.max(bytesNotified, loaded);
4457
4662
 
4458
4663
  const data = {
4459
4664
  loaded,
4460
4665
  total,
4461
- progress: total ? (loaded / total) : undefined,
4666
+ progress: total ? loaded / total : undefined,
4462
4667
  bytes: progressBytes,
4463
4668
  rate: rate ? rate : undefined,
4464
- estimated: rate && total && inRange ? (total - loaded) / rate : undefined,
4669
+ estimated: rate && total ? (total - loaded) / rate : undefined,
4465
4670
  event: e,
4466
4671
  lengthComputable: total != null,
4467
- [isDownloadStream ? 'download' : 'upload']: true
4672
+ [isDownloadStream ? 'download' : 'upload']: true,
4468
4673
  };
4469
4674
 
4470
4675
  listener(data);
4471
4676
  }, freq);
4472
- }
4677
+ };
4473
4678
 
4474
4679
  const progressEventDecorator = (total, throttled) => {
4475
4680
  const lengthComputable = total != null;
4476
4681
 
4477
- return [(loaded) => throttled[0]({
4478
- lengthComputable,
4479
- total,
4480
- loaded
4481
- }), throttled[1]];
4482
- }
4682
+ return [
4683
+ (loaded) =>
4684
+ throttled[0]({
4685
+ lengthComputable,
4686
+ total,
4687
+ loaded,
4688
+ }),
4689
+ throttled[1],
4690
+ ];
4691
+ };
4483
4692
 
4484
- const asyncDecorator = (fn) => (...args) => utils.asap(() => fn(...args));
4693
+ const asyncDecorator =
4694
+ (fn) =>
4695
+ (...args) =>
4696
+ utils.asap(() => fn(...args));
4485
4697
 
4486
4698
  ;// ../../../node_modules/axios/lib/helpers/isURLSameOrigin.js
4487
4699
 
4488
4700
 
4489
- /* harmony default export */ const isURLSameOrigin = (platform.hasStandardBrowserEnv ? ((origin, isMSIE) => (url) => {
4490
- url = new URL(url, platform.origin);
4701
+ /* harmony default export */ const isURLSameOrigin = (platform.hasStandardBrowserEnv
4702
+ ? ((origin, isMSIE) => (url) => {
4703
+ url = new URL(url, platform.origin);
4491
4704
 
4492
- return (
4493
- origin.protocol === url.protocol &&
4494
- origin.host === url.host &&
4495
- (isMSIE || origin.port === url.port)
4496
- );
4497
- })(
4498
- new URL(platform.origin),
4499
- platform.navigator && /(msie|trident)/i.test(platform.navigator.userAgent)
4500
- ) : () => true);
4705
+ return (
4706
+ origin.protocol === url.protocol &&
4707
+ origin.host === url.host &&
4708
+ (isMSIE || origin.port === url.port)
4709
+ );
4710
+ })(
4711
+ new URL(platform.origin),
4712
+ platform.navigator && /(msie|trident)/i.test(platform.navigator.userAgent)
4713
+ )
4714
+ : () => true);
4501
4715
 
4502
4716
  ;// ../../../node_modules/axios/lib/helpers/cookies.js
4503
4717
 
4504
4718
 
4505
4719
 
4506
- /* harmony default export */ const cookies = (platform.hasStandardBrowserEnv ?
4720
+ /* harmony default export */ const cookies = (platform.hasStandardBrowserEnv
4721
+ ? // Standard browser envs support document.cookie
4722
+ {
4723
+ write(name, value, expires, path, domain, secure, sameSite) {
4724
+ if (typeof document === 'undefined') return;
4507
4725
 
4508
- // Standard browser envs support document.cookie
4509
- {
4510
- write(name, value, expires, path, domain, secure, sameSite) {
4511
- if (typeof document === 'undefined') return;
4726
+ const cookie = [`${name}=${encodeURIComponent(value)}`];
4512
4727
 
4513
- const cookie = [`${name}=${encodeURIComponent(value)}`];
4514
-
4515
- if (utils.isNumber(expires)) {
4516
- cookie.push(`expires=${new Date(expires).toUTCString()}`);
4517
- }
4518
- if (utils.isString(path)) {
4519
- cookie.push(`path=${path}`);
4520
- }
4521
- if (utils.isString(domain)) {
4522
- cookie.push(`domain=${domain}`);
4523
- }
4524
- if (secure === true) {
4525
- cookie.push('secure');
4526
- }
4527
- if (utils.isString(sameSite)) {
4528
- cookie.push(`SameSite=${sameSite}`);
4529
- }
4728
+ if (utils.isNumber(expires)) {
4729
+ cookie.push(`expires=${new Date(expires).toUTCString()}`);
4730
+ }
4731
+ if (utils.isString(path)) {
4732
+ cookie.push(`path=${path}`);
4733
+ }
4734
+ if (utils.isString(domain)) {
4735
+ cookie.push(`domain=${domain}`);
4736
+ }
4737
+ if (secure === true) {
4738
+ cookie.push('secure');
4739
+ }
4740
+ if (utils.isString(sameSite)) {
4741
+ cookie.push(`SameSite=${sameSite}`);
4742
+ }
4530
4743
 
4531
- document.cookie = cookie.join('; ');
4532
- },
4744
+ document.cookie = cookie.join('; ');
4745
+ },
4533
4746
 
4534
- read(name) {
4535
- if (typeof document === 'undefined') return null;
4536
- const match = document.cookie.match(new RegExp('(?:^|; )' + name + '=([^;]*)'));
4537
- return match ? decodeURIComponent(match[1]) : null;
4538
- },
4747
+ read(name) {
4748
+ if (typeof document === 'undefined') return null;
4749
+ const match = document.cookie.match(new RegExp('(?:^|; )' + name + '=([^;]*)'));
4750
+ return match ? decodeURIComponent(match[1]) : null;
4751
+ },
4539
4752
 
4540
- remove(name) {
4541
- this.write(name, '', Date.now() - 86400000, '/');
4753
+ remove(name) {
4754
+ this.write(name, '', Date.now() - 86400000, '/');
4755
+ },
4542
4756
  }
4543
- }
4544
-
4545
- :
4546
-
4547
- // Non-standard browser env (web workers, react-native) lack needed support.
4548
- {
4549
- write() {},
4550
- read() {
4551
- return null;
4552
- },
4553
- remove() {}
4554
- });
4555
-
4757
+ : // Non-standard browser env (web workers, react-native) lack needed support.
4758
+ {
4759
+ write() {},
4760
+ read() {
4761
+ return null;
4762
+ },
4763
+ remove() {},
4764
+ });
4556
4765
 
4557
4766
  ;// ../../../node_modules/axios/lib/helpers/isAbsoluteURL.js
4558
4767
 
@@ -4575,7 +4784,6 @@ function isAbsoluteURL(url) {
4575
4784
  return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(url);
4576
4785
  }
4577
4786
 
4578
-
4579
4787
  ;// ../../../node_modules/axios/lib/helpers/combineURLs.js
4580
4788
 
4581
4789
 
@@ -4611,7 +4819,7 @@ function combineURLs(baseURL, relativeURL) {
4611
4819
  */
4612
4820
  function buildFullPath(baseURL, requestedURL, allowAbsoluteUrls) {
4613
4821
  let isRelativeUrl = !isAbsoluteURL(requestedURL);
4614
- if (baseURL && (isRelativeUrl || allowAbsoluteUrls == false)) {
4822
+ if (baseURL && (isRelativeUrl || allowAbsoluteUrls === false)) {
4615
4823
  return combineURLs(baseURL, requestedURL);
4616
4824
  }
4617
4825
  return requestedURL;
@@ -4623,8 +4831,7 @@ function buildFullPath(baseURL, requestedURL, allowAbsoluteUrls) {
4623
4831
 
4624
4832
 
4625
4833
 
4626
- const headersToObject = (thing) =>
4627
- thing instanceof core_AxiosHeaders ? { ...thing } : thing;
4834
+ const headersToObject = (thing) => (thing instanceof core_AxiosHeaders ? { ...thing } : thing);
4628
4835
 
4629
4836
  /**
4630
4837
  * Config-specific merge-function which creates a new config-object
@@ -4638,7 +4845,18 @@ const headersToObject = (thing) =>
4638
4845
  function mergeConfig(config1, config2) {
4639
4846
  // eslint-disable-next-line no-param-reassign
4640
4847
  config2 = config2 || {};
4641
- const config = {};
4848
+
4849
+ // Use a null-prototype object so that downstream reads such as `config.auth`
4850
+ // or `config.baseURL` cannot inherit polluted values from Object.prototype
4851
+ // (see GHSA-q8qp-cvcw-x6jj). `hasOwnProperty` is restored as a non-enumerable
4852
+ // own slot to preserve ergonomics for user code that relies on it.
4853
+ const config = Object.create(null);
4854
+ Object.defineProperty(config, 'hasOwnProperty', {
4855
+ value: Object.prototype.hasOwnProperty,
4856
+ enumerable: false,
4857
+ writable: true,
4858
+ configurable: true,
4859
+ });
4642
4860
 
4643
4861
  function getMergedValue(target, source, prop, caseless) {
4644
4862
  if (utils.isPlainObject(target) && utils.isPlainObject(source)) {
@@ -4677,9 +4895,9 @@ function mergeConfig(config1, config2) {
4677
4895
 
4678
4896
  // eslint-disable-next-line consistent-return
4679
4897
  function mergeDirectKeys(a, b, prop) {
4680
- if (prop in config2) {
4898
+ if (utils.hasOwnProp(config2, prop)) {
4681
4899
  return getMergedValue(a, b);
4682
- } else if (prop in config1) {
4900
+ } else if (utils.hasOwnProp(config1, prop)) {
4683
4901
  return getMergedValue(undefined, a);
4684
4902
  }
4685
4903
  }
@@ -4711,29 +4929,21 @@ function mergeConfig(config1, config2) {
4711
4929
  httpsAgent: defaultToConfig2,
4712
4930
  cancelToken: defaultToConfig2,
4713
4931
  socketPath: defaultToConfig2,
4932
+ allowedSocketPaths: defaultToConfig2,
4714
4933
  responseEncoding: defaultToConfig2,
4715
4934
  validateStatus: mergeDirectKeys,
4716
4935
  headers: (a, b, prop) =>
4717
4936
  mergeDeepProperties(headersToObject(a), headersToObject(b), prop, true),
4718
4937
  };
4719
4938
 
4720
- utils.forEach(
4721
- Object.keys({ ...config1, ...config2 }),
4722
- function computeConfigValue(prop) {
4723
- if (
4724
- prop === "__proto__" ||
4725
- prop === "constructor" ||
4726
- prop === "prototype"
4727
- )
4728
- return;
4729
- const merge = utils.hasOwnProp(mergeMap, prop)
4730
- ? mergeMap[prop]
4731
- : mergeDeepProperties;
4732
- const configValue = merge(config1[prop], config2[prop], prop);
4733
- (utils.isUndefined(configValue) && merge !== mergeDirectKeys) ||
4734
- (config[prop] = configValue);
4735
- },
4736
- );
4939
+ utils.forEach(Object.keys({ ...config1, ...config2 }), function computeConfigValue(prop) {
4940
+ if (prop === '__proto__' || prop === 'constructor' || prop === 'prototype') return;
4941
+ const merge = utils.hasOwnProp(mergeMap, prop) ? mergeMap[prop] : mergeDeepProperties;
4942
+ const a = utils.hasOwnProp(config1, prop) ? config1[prop] : undefined;
4943
+ const b = utils.hasOwnProp(config2, prop) ? config2[prop] : undefined;
4944
+ const configValue = merge(a, b, prop);
4945
+ (utils.isUndefined(configValue) && merge !== mergeDirectKeys) || (config[prop] = configValue);
4946
+ });
4737
4947
 
4738
4948
  return config;
4739
4949
  }
@@ -4751,16 +4961,38 @@ function mergeConfig(config1, config2) {
4751
4961
  /* harmony default export */ const resolveConfig = ((config) => {
4752
4962
  const newConfig = mergeConfig({}, config);
4753
4963
 
4754
- let { data, withXSRFToken, xsrfHeaderName, xsrfCookieName, headers, auth } = newConfig;
4964
+ // Read only own properties to prevent prototype pollution gadgets
4965
+ // (e.g. Object.prototype.baseURL = 'https://evil.com'). See GHSA-q8qp-cvcw-x6jj.
4966
+ const own = (key) => (utils.hasOwnProp(newConfig, key) ? newConfig[key] : undefined);
4967
+
4968
+ const data = own('data');
4969
+ let withXSRFToken = own('withXSRFToken');
4970
+ const xsrfHeaderName = own('xsrfHeaderName');
4971
+ const xsrfCookieName = own('xsrfCookieName');
4972
+ let headers = own('headers');
4973
+ const auth = own('auth');
4974
+ const baseURL = own('baseURL');
4975
+ const allowAbsoluteUrls = own('allowAbsoluteUrls');
4976
+ const url = own('url');
4755
4977
 
4756
4978
  newConfig.headers = headers = core_AxiosHeaders.from(headers);
4757
4979
 
4758
- newConfig.url = buildURL(buildFullPath(newConfig.baseURL, newConfig.url, newConfig.allowAbsoluteUrls), config.params, config.paramsSerializer);
4980
+ newConfig.url = buildURL(
4981
+ buildFullPath(baseURL, url, allowAbsoluteUrls),
4982
+ config.params,
4983
+ config.paramsSerializer
4984
+ );
4759
4985
 
4760
4986
  // HTTP basic authentication
4761
4987
  if (auth) {
4762
- headers.set('Authorization', 'Basic ' +
4763
- btoa((auth.username || '') + ':' + (auth.password ? unescape(encodeURIComponent(auth.password)) : ''))
4988
+ headers.set(
4989
+ 'Authorization',
4990
+ 'Basic ' +
4991
+ btoa(
4992
+ (auth.username || '') +
4993
+ ':' +
4994
+ (auth.password ? unescape(encodeURIComponent(auth.password)) : '')
4995
+ )
4764
4996
  );
4765
4997
  }
4766
4998
 
@@ -4778,17 +5010,25 @@ function mergeConfig(config1, config2) {
4778
5010
  }
4779
5011
  });
4780
5012
  }
4781
- }
5013
+ }
4782
5014
 
4783
5015
  // Add xsrf header
4784
5016
  // This is only done if running in a standard browser environment.
4785
5017
  // Specifically not if we're in a web worker, or react-native.
4786
5018
 
4787
5019
  if (platform.hasStandardBrowserEnv) {
4788
- withXSRFToken && utils.isFunction(withXSRFToken) && (withXSRFToken = withXSRFToken(newConfig));
5020
+ if (utils.isFunction(withXSRFToken)) {
5021
+ withXSRFToken = withXSRFToken(newConfig);
5022
+ }
5023
+
5024
+ // Strict boolean check — prevents proto-pollution gadgets (e.g. Object.prototype.withXSRFToken = 1)
5025
+ // and misconfigurations (e.g. "false") from short-circuiting the same-origin check and leaking
5026
+ // the XSRF token cross-origin. See GHSA-xx6v-rp6x-q39c.
5027
+ const shouldSendXSRF =
5028
+ withXSRFToken === true ||
5029
+ (withXSRFToken == null && isURLSameOrigin(newConfig.url));
4789
5030
 
4790
- if (withXSRFToken || (withXSRFToken !== false && isURLSameOrigin(newConfig.url))) {
4791
- // Add xsrf header
5031
+ if (shouldSendXSRF) {
4792
5032
  const xsrfValue = xsrfHeaderName && xsrfCookieName && cookies.read(xsrfCookieName);
4793
5033
 
4794
5034
  if (xsrfValue) {
@@ -4800,7 +5040,6 @@ function mergeConfig(config1, config2) {
4800
5040
  return newConfig;
4801
5041
  });
4802
5042
 
4803
-
4804
5043
  ;// ../../../node_modules/axios/lib/adapters/xhr.js
4805
5044
 
4806
5045
 
@@ -4815,193 +5054,215 @@ function mergeConfig(config1, config2) {
4815
5054
 
4816
5055
  const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
4817
5056
 
4818
- /* harmony default export */ const xhr = (isXHRAdapterSupported && function (config) {
4819
- return new Promise(function dispatchXhrRequest(resolve, reject) {
4820
- const _config = resolveConfig(config);
4821
- let requestData = _config.data;
4822
- const requestHeaders = core_AxiosHeaders.from(_config.headers).normalize();
4823
- let {responseType, onUploadProgress, onDownloadProgress} = _config;
4824
- let onCanceled;
4825
- let uploadThrottled, downloadThrottled;
4826
- let flushUpload, flushDownload;
5057
+ /* harmony default export */ const xhr = (isXHRAdapterSupported &&
5058
+ function (config) {
5059
+ return new Promise(function dispatchXhrRequest(resolve, reject) {
5060
+ const _config = resolveConfig(config);
5061
+ let requestData = _config.data;
5062
+ const requestHeaders = core_AxiosHeaders.from(_config.headers).normalize();
5063
+ let { responseType, onUploadProgress, onDownloadProgress } = _config;
5064
+ let onCanceled;
5065
+ let uploadThrottled, downloadThrottled;
5066
+ let flushUpload, flushDownload;
4827
5067
 
4828
- function done() {
4829
- flushUpload && flushUpload(); // flush events
4830
- flushDownload && flushDownload(); // flush events
5068
+ function done() {
5069
+ flushUpload && flushUpload(); // flush events
5070
+ flushDownload && flushDownload(); // flush events
4831
5071
 
4832
- _config.cancelToken && _config.cancelToken.unsubscribe(onCanceled);
5072
+ _config.cancelToken && _config.cancelToken.unsubscribe(onCanceled);
4833
5073
 
4834
- _config.signal && _config.signal.removeEventListener('abort', onCanceled);
4835
- }
5074
+ _config.signal && _config.signal.removeEventListener('abort', onCanceled);
5075
+ }
4836
5076
 
4837
- let request = new XMLHttpRequest();
5077
+ let request = new XMLHttpRequest();
4838
5078
 
4839
- request.open(_config.method.toUpperCase(), _config.url, true);
5079
+ request.open(_config.method.toUpperCase(), _config.url, true);
4840
5080
 
4841
- // Set the request timeout in MS
4842
- request.timeout = _config.timeout;
5081
+ // Set the request timeout in MS
5082
+ request.timeout = _config.timeout;
4843
5083
 
4844
- function onloadend() {
4845
- if (!request) {
4846
- return;
5084
+ function onloadend() {
5085
+ if (!request) {
5086
+ return;
5087
+ }
5088
+ // Prepare the response
5089
+ const responseHeaders = core_AxiosHeaders.from(
5090
+ 'getAllResponseHeaders' in request && request.getAllResponseHeaders()
5091
+ );
5092
+ const responseData =
5093
+ !responseType || responseType === 'text' || responseType === 'json'
5094
+ ? request.responseText
5095
+ : request.response;
5096
+ const response = {
5097
+ data: responseData,
5098
+ status: request.status,
5099
+ statusText: request.statusText,
5100
+ headers: responseHeaders,
5101
+ config,
5102
+ request,
5103
+ };
5104
+
5105
+ settle(
5106
+ function _resolve(value) {
5107
+ resolve(value);
5108
+ done();
5109
+ },
5110
+ function _reject(err) {
5111
+ reject(err);
5112
+ done();
5113
+ },
5114
+ response
5115
+ );
5116
+
5117
+ // Clean up request
5118
+ request = null;
4847
5119
  }
4848
- // Prepare the response
4849
- const responseHeaders = core_AxiosHeaders.from(
4850
- 'getAllResponseHeaders' in request && request.getAllResponseHeaders()
4851
- );
4852
- const responseData = !responseType || responseType === 'text' || responseType === 'json' ?
4853
- request.responseText : request.response;
4854
- const response = {
4855
- data: responseData,
4856
- status: request.status,
4857
- statusText: request.statusText,
4858
- headers: responseHeaders,
4859
- config,
4860
- request
4861
- };
4862
5120
 
4863
- settle(function _resolve(value) {
4864
- resolve(value);
4865
- done();
4866
- }, function _reject(err) {
4867
- reject(err);
4868
- done();
4869
- }, response);
5121
+ if ('onloadend' in request) {
5122
+ // Use onloadend if available
5123
+ request.onloadend = onloadend;
5124
+ } else {
5125
+ // Listen for ready state to emulate onloadend
5126
+ request.onreadystatechange = function handleLoad() {
5127
+ if (!request || request.readyState !== 4) {
5128
+ return;
5129
+ }
4870
5130
 
4871
- // Clean up request
4872
- request = null;
4873
- }
5131
+ // The request errored out and we didn't get a response, this will be
5132
+ // handled by onerror instead
5133
+ // With one exception: request that using file: protocol, most browsers
5134
+ // will return status as 0 even though it's a successful request
5135
+ if (
5136
+ request.status === 0 &&
5137
+ !(request.responseURL && request.responseURL.indexOf('file:') === 0)
5138
+ ) {
5139
+ return;
5140
+ }
5141
+ // readystate handler is calling before onerror or ontimeout handlers,
5142
+ // so we should call onloadend on the next 'tick'
5143
+ setTimeout(onloadend);
5144
+ };
5145
+ }
4874
5146
 
4875
- if ('onloadend' in request) {
4876
- // Use onloadend if available
4877
- request.onloadend = onloadend;
4878
- } else {
4879
- // Listen for ready state to emulate onloadend
4880
- request.onreadystatechange = function handleLoad() {
4881
- if (!request || request.readyState !== 4) {
5147
+ // Handle browser request cancellation (as opposed to a manual cancellation)
5148
+ request.onabort = function handleAbort() {
5149
+ if (!request) {
4882
5150
  return;
4883
5151
  }
4884
5152
 
4885
- // The request errored out and we didn't get a response, this will be
4886
- // handled by onerror instead
4887
- // With one exception: request that using file: protocol, most browsers
4888
- // will return status as 0 even though it's a successful request
4889
- if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) {
4890
- return;
4891
- }
4892
- // readystate handler is calling before onerror or ontimeout handlers,
4893
- // so we should call onloadend on the next 'tick'
4894
- setTimeout(onloadend);
5153
+ reject(new core_AxiosError('Request aborted', core_AxiosError.ECONNABORTED, config, request));
5154
+
5155
+ // Clean up request
5156
+ request = null;
4895
5157
  };
4896
- }
4897
5158
 
4898
- // Handle browser request cancellation (as opposed to a manual cancellation)
4899
- request.onabort = function handleAbort() {
4900
- if (!request) {
4901
- return;
4902
- }
5159
+ // Handle low level network errors
5160
+ request.onerror = function handleError(event) {
5161
+ // Browsers deliver a ProgressEvent in XHR onerror
5162
+ // (message may be empty; when present, surface it)
5163
+ // See https://developer.mozilla.org/docs/Web/API/XMLHttpRequest/error_event
5164
+ const msg = event && event.message ? event.message : 'Network Error';
5165
+ const err = new core_AxiosError(msg, core_AxiosError.ERR_NETWORK, config, request);
5166
+ // attach the underlying event for consumers who want details
5167
+ err.event = event || null;
5168
+ reject(err);
5169
+ request = null;
5170
+ };
4903
5171
 
4904
- reject(new core_AxiosError('Request aborted', core_AxiosError.ECONNABORTED, config, request));
5172
+ // Handle timeout
5173
+ request.ontimeout = function handleTimeout() {
5174
+ let timeoutErrorMessage = _config.timeout
5175
+ ? 'timeout of ' + _config.timeout + 'ms exceeded'
5176
+ : 'timeout exceeded';
5177
+ const transitional = _config.transitional || defaults_transitional;
5178
+ if (_config.timeoutErrorMessage) {
5179
+ timeoutErrorMessage = _config.timeoutErrorMessage;
5180
+ }
5181
+ reject(
5182
+ new core_AxiosError(
5183
+ timeoutErrorMessage,
5184
+ transitional.clarifyTimeoutError ? core_AxiosError.ETIMEDOUT : core_AxiosError.ECONNABORTED,
5185
+ config,
5186
+ request
5187
+ )
5188
+ );
4905
5189
 
4906
- // Clean up request
4907
- request = null;
4908
- };
5190
+ // Clean up request
5191
+ request = null;
5192
+ };
4909
5193
 
4910
- // Handle low level network errors
4911
- request.onerror = function handleError(event) {
4912
- // Browsers deliver a ProgressEvent in XHR onerror
4913
- // (message may be empty; when present, surface it)
4914
- // See https://developer.mozilla.org/docs/Web/API/XMLHttpRequest/error_event
4915
- const msg = event && event.message ? event.message : 'Network Error';
4916
- const err = new core_AxiosError(msg, core_AxiosError.ERR_NETWORK, config, request);
4917
- // attach the underlying event for consumers who want details
4918
- err.event = event || null;
4919
- reject(err);
4920
- request = null;
4921
- };
4922
-
4923
- // Handle timeout
4924
- request.ontimeout = function handleTimeout() {
4925
- let timeoutErrorMessage = _config.timeout ? 'timeout of ' + _config.timeout + 'ms exceeded' : 'timeout exceeded';
4926
- const transitional = _config.transitional || defaults_transitional;
4927
- if (_config.timeoutErrorMessage) {
4928
- timeoutErrorMessage = _config.timeoutErrorMessage;
4929
- }
4930
- reject(new core_AxiosError(
4931
- timeoutErrorMessage,
4932
- transitional.clarifyTimeoutError ? core_AxiosError.ETIMEDOUT : core_AxiosError.ECONNABORTED,
4933
- config,
4934
- request));
4935
-
4936
- // Clean up request
4937
- request = null;
4938
- };
5194
+ // Remove Content-Type if data is undefined
5195
+ requestData === undefined && requestHeaders.setContentType(null);
4939
5196
 
4940
- // Remove Content-Type if data is undefined
4941
- requestData === undefined && requestHeaders.setContentType(null);
5197
+ // Add headers to the request
5198
+ if ('setRequestHeader' in request) {
5199
+ utils.forEach(requestHeaders.toJSON(), function setRequestHeader(val, key) {
5200
+ request.setRequestHeader(key, val);
5201
+ });
5202
+ }
4942
5203
 
4943
- // Add headers to the request
4944
- if ('setRequestHeader' in request) {
4945
- utils.forEach(requestHeaders.toJSON(), function setRequestHeader(val, key) {
4946
- request.setRequestHeader(key, val);
4947
- });
4948
- }
5204
+ // Add withCredentials to request if needed
5205
+ if (!utils.isUndefined(_config.withCredentials)) {
5206
+ request.withCredentials = !!_config.withCredentials;
5207
+ }
4949
5208
 
4950
- // Add withCredentials to request if needed
4951
- if (!utils.isUndefined(_config.withCredentials)) {
4952
- request.withCredentials = !!_config.withCredentials;
4953
- }
5209
+ // Add responseType to request if needed
5210
+ if (responseType && responseType !== 'json') {
5211
+ request.responseType = _config.responseType;
5212
+ }
4954
5213
 
4955
- // Add responseType to request if needed
4956
- if (responseType && responseType !== 'json') {
4957
- request.responseType = _config.responseType;
4958
- }
5214
+ // Handle progress if needed
5215
+ if (onDownloadProgress) {
5216
+ [downloadThrottled, flushDownload] = progressEventReducer(onDownloadProgress, true);
5217
+ request.addEventListener('progress', downloadThrottled);
5218
+ }
4959
5219
 
4960
- // Handle progress if needed
4961
- if (onDownloadProgress) {
4962
- ([downloadThrottled, flushDownload] = progressEventReducer(onDownloadProgress, true));
4963
- request.addEventListener('progress', downloadThrottled);
4964
- }
5220
+ // Not all browsers support upload events
5221
+ if (onUploadProgress && request.upload) {
5222
+ [uploadThrottled, flushUpload] = progressEventReducer(onUploadProgress);
4965
5223
 
4966
- // Not all browsers support upload events
4967
- if (onUploadProgress && request.upload) {
4968
- ([uploadThrottled, flushUpload] = progressEventReducer(onUploadProgress));
5224
+ request.upload.addEventListener('progress', uploadThrottled);
4969
5225
 
4970
- request.upload.addEventListener('progress', uploadThrottled);
5226
+ request.upload.addEventListener('loadend', flushUpload);
5227
+ }
4971
5228
 
4972
- request.upload.addEventListener('loadend', flushUpload);
4973
- }
5229
+ if (_config.cancelToken || _config.signal) {
5230
+ // Handle cancellation
5231
+ // eslint-disable-next-line func-names
5232
+ onCanceled = (cancel) => {
5233
+ if (!request) {
5234
+ return;
5235
+ }
5236
+ reject(!cancel || cancel.type ? new cancel_CanceledError(null, config, request) : cancel);
5237
+ request.abort();
5238
+ request = null;
5239
+ };
4974
5240
 
4975
- if (_config.cancelToken || _config.signal) {
4976
- // Handle cancellation
4977
- // eslint-disable-next-line func-names
4978
- onCanceled = cancel => {
4979
- if (!request) {
4980
- return;
5241
+ _config.cancelToken && _config.cancelToken.subscribe(onCanceled);
5242
+ if (_config.signal) {
5243
+ _config.signal.aborted
5244
+ ? onCanceled()
5245
+ : _config.signal.addEventListener('abort', onCanceled);
4981
5246
  }
4982
- reject(!cancel || cancel.type ? new cancel_CanceledError(null, config, request) : cancel);
4983
- request.abort();
4984
- request = null;
4985
- };
4986
-
4987
- _config.cancelToken && _config.cancelToken.subscribe(onCanceled);
4988
- if (_config.signal) {
4989
- _config.signal.aborted ? onCanceled() : _config.signal.addEventListener('abort', onCanceled);
4990
5247
  }
4991
- }
4992
5248
 
4993
- const protocol = parseProtocol(_config.url);
4994
-
4995
- if (protocol && platform.protocols.indexOf(protocol) === -1) {
4996
- reject(new core_AxiosError('Unsupported protocol ' + protocol + ':', core_AxiosError.ERR_BAD_REQUEST, config));
4997
- return;
4998
- }
5249
+ const protocol = parseProtocol(_config.url);
4999
5250
 
5251
+ if (protocol && platform.protocols.indexOf(protocol) === -1) {
5252
+ reject(
5253
+ new core_AxiosError(
5254
+ 'Unsupported protocol ' + protocol + ':',
5255
+ core_AxiosError.ERR_BAD_REQUEST,
5256
+ config
5257
+ )
5258
+ );
5259
+ return;
5260
+ }
5000
5261
 
5001
- // Send the request
5002
- request.send(requestData || null);
5262
+ // Send the request
5263
+ request.send(requestData || null);
5264
+ });
5003
5265
  });
5004
- });
5005
5266
 
5006
5267
  ;// ../../../node_modules/axios/lib/helpers/composeSignals.js
5007
5268
 
@@ -5009,7 +5270,7 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
5009
5270
 
5010
5271
 
5011
5272
  const composeSignals = (signals, timeout) => {
5012
- const {length} = (signals = signals ? signals.filter(Boolean) : []);
5273
+ const { length } = (signals = signals ? signals.filter(Boolean) : []);
5013
5274
 
5014
5275
  if (timeout || length) {
5015
5276
  let controller = new AbortController();
@@ -5021,40 +5282,47 @@ const composeSignals = (signals, timeout) => {
5021
5282
  aborted = true;
5022
5283
  unsubscribe();
5023
5284
  const err = reason instanceof Error ? reason : this.reason;
5024
- controller.abort(err instanceof core_AxiosError ? err : new cancel_CanceledError(err instanceof Error ? err.message : err));
5285
+ controller.abort(
5286
+ err instanceof core_AxiosError
5287
+ ? err
5288
+ : new cancel_CanceledError(err instanceof Error ? err.message : err)
5289
+ );
5025
5290
  }
5026
- }
5291
+ };
5027
5292
 
5028
- let timer = timeout && setTimeout(() => {
5029
- timer = null;
5030
- onabort(new core_AxiosError(`timeout of ${timeout}ms exceeded`, core_AxiosError.ETIMEDOUT))
5031
- }, timeout)
5293
+ let timer =
5294
+ timeout &&
5295
+ setTimeout(() => {
5296
+ timer = null;
5297
+ onabort(new core_AxiosError(`timeout of ${timeout}ms exceeded`, core_AxiosError.ETIMEDOUT));
5298
+ }, timeout);
5032
5299
 
5033
5300
  const unsubscribe = () => {
5034
5301
  if (signals) {
5035
5302
  timer && clearTimeout(timer);
5036
5303
  timer = null;
5037
- signals.forEach(signal => {
5038
- signal.unsubscribe ? signal.unsubscribe(onabort) : signal.removeEventListener('abort', onabort);
5304
+ signals.forEach((signal) => {
5305
+ signal.unsubscribe
5306
+ ? signal.unsubscribe(onabort)
5307
+ : signal.removeEventListener('abort', onabort);
5039
5308
  });
5040
5309
  signals = null;
5041
5310
  }
5042
- }
5311
+ };
5043
5312
 
5044
5313
  signals.forEach((signal) => signal.addEventListener('abort', onabort));
5045
5314
 
5046
- const {signal} = controller;
5315
+ const { signal } = controller;
5047
5316
 
5048
5317
  signal.unsubscribe = () => utils.asap(unsubscribe);
5049
5318
 
5050
5319
  return signal;
5051
5320
  }
5052
- }
5321
+ };
5053
5322
 
5054
5323
  /* harmony default export */ const helpers_composeSignals = (composeSignals);
5055
5324
 
5056
5325
  ;// ../../../node_modules/axios/lib/helpers/trackStream.js
5057
-
5058
5326
  const streamChunk = function* (chunk, chunkSize) {
5059
5327
  let len = chunk.byteLength;
5060
5328
 
@@ -5071,13 +5339,13 @@ const streamChunk = function* (chunk, chunkSize) {
5071
5339
  yield chunk.slice(pos, end);
5072
5340
  pos = end;
5073
5341
  }
5074
- }
5342
+ };
5075
5343
 
5076
5344
  const readBytes = async function* (iterable, chunkSize) {
5077
5345
  for await (const chunk of readStream(iterable)) {
5078
5346
  yield* streamChunk(chunk, chunkSize);
5079
5347
  }
5080
- }
5348
+ };
5081
5349
 
5082
5350
  const readStream = async function* (stream) {
5083
5351
  if (stream[Symbol.asyncIterator]) {
@@ -5088,7 +5356,7 @@ const readStream = async function* (stream) {
5088
5356
  const reader = stream.getReader();
5089
5357
  try {
5090
5358
  for (;;) {
5091
- const {done, value} = await reader.read();
5359
+ const { done, value } = await reader.read();
5092
5360
  if (done) {
5093
5361
  break;
5094
5362
  }
@@ -5097,7 +5365,7 @@ const readStream = async function* (stream) {
5097
5365
  } finally {
5098
5366
  await reader.cancel();
5099
5367
  }
5100
- }
5368
+ };
5101
5369
 
5102
5370
  const trackStream = (stream, chunkSize, onProgress, onFinish) => {
5103
5371
  const iterator = readBytes(stream, chunkSize);
@@ -5109,38 +5377,41 @@ const trackStream = (stream, chunkSize, onProgress, onFinish) => {
5109
5377
  done = true;
5110
5378
  onFinish && onFinish(e);
5111
5379
  }
5112
- }
5380
+ };
5113
5381
 
5114
- return new ReadableStream({
5115
- async pull(controller) {
5116
- try {
5117
- const {done, value} = await iterator.next();
5382
+ return new ReadableStream(
5383
+ {
5384
+ async pull(controller) {
5385
+ try {
5386
+ const { done, value } = await iterator.next();
5118
5387
 
5119
- if (done) {
5120
- _onFinish();
5121
- controller.close();
5122
- return;
5123
- }
5388
+ if (done) {
5389
+ _onFinish();
5390
+ controller.close();
5391
+ return;
5392
+ }
5124
5393
 
5125
- let len = value.byteLength;
5126
- if (onProgress) {
5127
- let loadedBytes = bytes += len;
5128
- onProgress(loadedBytes);
5394
+ let len = value.byteLength;
5395
+ if (onProgress) {
5396
+ let loadedBytes = (bytes += len);
5397
+ onProgress(loadedBytes);
5398
+ }
5399
+ controller.enqueue(new Uint8Array(value));
5400
+ } catch (err) {
5401
+ _onFinish(err);
5402
+ throw err;
5129
5403
  }
5130
- controller.enqueue(new Uint8Array(value));
5131
- } catch (err) {
5132
- _onFinish(err);
5133
- throw err;
5134
- }
5404
+ },
5405
+ cancel(reason) {
5406
+ _onFinish(reason);
5407
+ return iterator.return();
5408
+ },
5135
5409
  },
5136
- cancel(reason) {
5137
- _onFinish(reason);
5138
- return iterator.return();
5410
+ {
5411
+ highWaterMark: 2,
5139
5412
  }
5140
- }, {
5141
- highWaterMark: 2
5142
- })
5143
- }
5413
+ );
5414
+ };
5144
5415
 
5145
5416
  ;// ../../../node_modules/axios/lib/adapters/fetch.js
5146
5417
 
@@ -5155,31 +5426,33 @@ const trackStream = (stream, chunkSize, onProgress, onFinish) => {
5155
5426
 
5156
5427
  const DEFAULT_CHUNK_SIZE = 64 * 1024;
5157
5428
 
5158
- const {isFunction: fetch_isFunction} = utils;
5429
+ const { isFunction: fetch_isFunction } = utils;
5159
5430
 
5160
- const globalFetchAPI = (({Request, Response}) => ({
5161
- Request, Response
5431
+ const globalFetchAPI = (({ Request, Response }) => ({
5432
+ Request,
5433
+ Response,
5162
5434
  }))(utils.global);
5163
5435
 
5164
- const {
5165
- ReadableStream: fetch_ReadableStream, TextEncoder
5166
- } = utils.global;
5167
-
5436
+ const { ReadableStream: fetch_ReadableStream, TextEncoder } = utils.global;
5168
5437
 
5169
5438
  const test = (fn, ...args) => {
5170
5439
  try {
5171
5440
  return !!fn(...args);
5172
5441
  } catch (e) {
5173
- return false
5442
+ return false;
5174
5443
  }
5175
- }
5444
+ };
5176
5445
 
5177
5446
  const factory = (env) => {
5178
- env = utils.merge.call({
5179
- skipUndefined: true
5180
- }, globalFetchAPI, env);
5447
+ env = utils.merge.call(
5448
+ {
5449
+ skipUndefined: true,
5450
+ },
5451
+ globalFetchAPI,
5452
+ env
5453
+ );
5181
5454
 
5182
- const {fetch: envFetch, Request, Response} = env;
5455
+ const { fetch: envFetch, Request, Response } = env;
5183
5456
  const isFetchSupported = envFetch ? fetch_isFunction(envFetch) : typeof fetch === 'function';
5184
5457
  const isRequestSupported = fetch_isFunction(Request);
5185
5458
  const isResponseSupported = fetch_isFunction(Response);
@@ -5190,46 +5463,67 @@ const factory = (env) => {
5190
5463
 
5191
5464
  const isReadableStreamSupported = isFetchSupported && fetch_isFunction(fetch_ReadableStream);
5192
5465
 
5193
- const encodeText = isFetchSupported && (typeof TextEncoder === 'function' ?
5194
- ((encoder) => (str) => encoder.encode(str))(new TextEncoder()) :
5195
- async (str) => new Uint8Array(await new Request(str).arrayBuffer())
5196
- );
5466
+ const encodeText =
5467
+ isFetchSupported &&
5468
+ (typeof TextEncoder === 'function'
5469
+ ? (
5470
+ (encoder) => (str) =>
5471
+ encoder.encode(str)
5472
+ )(new TextEncoder())
5473
+ : async (str) => new Uint8Array(await new Request(str).arrayBuffer()));
5474
+
5475
+ const supportsRequestStream =
5476
+ isRequestSupported &&
5477
+ isReadableStreamSupported &&
5478
+ test(() => {
5479
+ let duplexAccessed = false;
5480
+
5481
+ const request = new Request(platform.origin, {
5482
+ body: new fetch_ReadableStream(),
5483
+ method: 'POST',
5484
+ get duplex() {
5485
+ duplexAccessed = true;
5486
+ return 'half';
5487
+ },
5488
+ });
5197
5489
 
5198
- const supportsRequestStream = isRequestSupported && isReadableStreamSupported && test(() => {
5199
- let duplexAccessed = false;
5490
+ const hasContentType = request.headers.has('Content-Type');
5200
5491
 
5201
- const hasContentType = new Request(platform.origin, {
5202
- body: new fetch_ReadableStream(),
5203
- method: 'POST',
5204
- get duplex() {
5205
- duplexAccessed = true;
5206
- return 'half';
5207
- },
5208
- }).headers.has('Content-Type');
5492
+ if (request.body != null) {
5493
+ request.body.cancel();
5494
+ }
5209
5495
 
5210
- return duplexAccessed && !hasContentType;
5211
- });
5496
+ return duplexAccessed && !hasContentType;
5497
+ });
5212
5498
 
5213
- const supportsResponseStream = isResponseSupported && isReadableStreamSupported &&
5499
+ const supportsResponseStream =
5500
+ isResponseSupported &&
5501
+ isReadableStreamSupported &&
5214
5502
  test(() => utils.isReadableStream(new Response('').body));
5215
5503
 
5216
5504
  const resolvers = {
5217
- stream: supportsResponseStream && ((res) => res.body)
5505
+ stream: supportsResponseStream && ((res) => res.body),
5218
5506
  };
5219
5507
 
5220
- isFetchSupported && ((() => {
5221
- ['text', 'arrayBuffer', 'blob', 'formData', 'stream'].forEach(type => {
5222
- !resolvers[type] && (resolvers[type] = (res, config) => {
5223
- let method = res && res[type];
5508
+ isFetchSupported &&
5509
+ (() => {
5510
+ ['text', 'arrayBuffer', 'blob', 'formData', 'stream'].forEach((type) => {
5511
+ !resolvers[type] &&
5512
+ (resolvers[type] = (res, config) => {
5513
+ let method = res && res[type];
5224
5514
 
5225
- if (method) {
5226
- return method.call(res);
5227
- }
5515
+ if (method) {
5516
+ return method.call(res);
5517
+ }
5228
5518
 
5229
- throw new core_AxiosError(`Response type '${type}' is not supported`, core_AxiosError.ERR_NOT_SUPPORT, config);
5230
- })
5231
- });
5232
- })());
5519
+ throw new core_AxiosError(
5520
+ `Response type '${type}' is not supported`,
5521
+ core_AxiosError.ERR_NOT_SUPPORT,
5522
+ config
5523
+ );
5524
+ });
5525
+ });
5526
+ })();
5233
5527
 
5234
5528
  const getBodyLength = async (body) => {
5235
5529
  if (body == null) {
@@ -5259,13 +5553,13 @@ const factory = (env) => {
5259
5553
  if (utils.isString(body)) {
5260
5554
  return (await encodeText(body)).byteLength;
5261
5555
  }
5262
- }
5556
+ };
5263
5557
 
5264
5558
  const resolveBodyLength = async (headers, body) => {
5265
5559
  const length = utils.toFiniteNumber(headers.getContentLength());
5266
5560
 
5267
5561
  return length == null ? getBodyLength(body) : length;
5268
- }
5562
+ };
5269
5563
 
5270
5564
  return async (config) => {
5271
5565
  let {
@@ -5280,38 +5574,47 @@ const factory = (env) => {
5280
5574
  responseType,
5281
5575
  headers,
5282
5576
  withCredentials = 'same-origin',
5283
- fetchOptions
5577
+ fetchOptions,
5284
5578
  } = resolveConfig(config);
5285
5579
 
5286
5580
  let _fetch = envFetch || fetch;
5287
5581
 
5288
5582
  responseType = responseType ? (responseType + '').toLowerCase() : 'text';
5289
5583
 
5290
- let composedSignal = helpers_composeSignals([signal, cancelToken && cancelToken.toAbortSignal()], timeout);
5584
+ let composedSignal = helpers_composeSignals(
5585
+ [signal, cancelToken && cancelToken.toAbortSignal()],
5586
+ timeout
5587
+ );
5291
5588
 
5292
5589
  let request = null;
5293
5590
 
5294
- const unsubscribe = composedSignal && composedSignal.unsubscribe && (() => {
5295
- composedSignal.unsubscribe();
5296
- });
5591
+ const unsubscribe =
5592
+ composedSignal &&
5593
+ composedSignal.unsubscribe &&
5594
+ (() => {
5595
+ composedSignal.unsubscribe();
5596
+ });
5297
5597
 
5298
5598
  let requestContentLength;
5299
5599
 
5300
5600
  try {
5301
5601
  if (
5302
- onUploadProgress && supportsRequestStream && method !== 'get' && method !== 'head' &&
5602
+ onUploadProgress &&
5603
+ supportsRequestStream &&
5604
+ method !== 'get' &&
5605
+ method !== 'head' &&
5303
5606
  (requestContentLength = await resolveBodyLength(headers, data)) !== 0
5304
5607
  ) {
5305
5608
  let _request = new Request(url, {
5306
5609
  method: 'POST',
5307
5610
  body: data,
5308
- duplex: "half"
5611
+ duplex: 'half',
5309
5612
  });
5310
5613
 
5311
5614
  let contentTypeHeader;
5312
5615
 
5313
5616
  if (utils.isFormData(data) && (contentTypeHeader = _request.headers.get('content-type'))) {
5314
- headers.setContentType(contentTypeHeader)
5617
+ headers.setContentType(contentTypeHeader);
5315
5618
  }
5316
5619
 
5317
5620
  if (_request.body) {
@@ -5330,7 +5633,20 @@ const factory = (env) => {
5330
5633
 
5331
5634
  // Cloudflare Workers throws when credentials are defined
5332
5635
  // see https://github.com/cloudflare/workerd/issues/902
5333
- const isCredentialsSupported = isRequestSupported && "credentials" in Request.prototype;
5636
+ const isCredentialsSupported = isRequestSupported && 'credentials' in Request.prototype;
5637
+
5638
+ // If data is FormData and Content-Type is multipart/form-data without boundary,
5639
+ // delete it so fetch can set it correctly with the boundary
5640
+ if (utils.isFormData(data)) {
5641
+ const contentType = headers.getContentType();
5642
+ if (
5643
+ contentType &&
5644
+ /^multipart\/form-data/i.test(contentType) &&
5645
+ !/boundary=/i.test(contentType)
5646
+ ) {
5647
+ headers.delete('content-type');
5648
+ }
5649
+ }
5334
5650
 
5335
5651
  const resolvedOptions = {
5336
5652
  ...fetchOptions,
@@ -5338,29 +5654,35 @@ const factory = (env) => {
5338
5654
  method: method.toUpperCase(),
5339
5655
  headers: headers.normalize().toJSON(),
5340
5656
  body: data,
5341
- duplex: "half",
5342
- credentials: isCredentialsSupported ? withCredentials : undefined
5657
+ duplex: 'half',
5658
+ credentials: isCredentialsSupported ? withCredentials : undefined,
5343
5659
  };
5344
5660
 
5345
5661
  request = isRequestSupported && new Request(url, resolvedOptions);
5346
5662
 
5347
- let response = await (isRequestSupported ? _fetch(request, fetchOptions) : _fetch(url, resolvedOptions));
5663
+ let response = await (isRequestSupported
5664
+ ? _fetch(request, fetchOptions)
5665
+ : _fetch(url, resolvedOptions));
5348
5666
 
5349
- const isStreamResponse = supportsResponseStream && (responseType === 'stream' || responseType === 'response');
5667
+ const isStreamResponse =
5668
+ supportsResponseStream && (responseType === 'stream' || responseType === 'response');
5350
5669
 
5351
5670
  if (supportsResponseStream && (onDownloadProgress || (isStreamResponse && unsubscribe))) {
5352
5671
  const options = {};
5353
5672
 
5354
- ['status', 'statusText', 'headers'].forEach(prop => {
5673
+ ['status', 'statusText', 'headers'].forEach((prop) => {
5355
5674
  options[prop] = response[prop];
5356
5675
  });
5357
5676
 
5358
5677
  const responseContentLength = utils.toFiniteNumber(response.headers.get('content-length'));
5359
5678
 
5360
- const [onProgress, flush] = onDownloadProgress && progressEventDecorator(
5361
- responseContentLength,
5362
- progressEventReducer(asyncDecorator(onDownloadProgress), true)
5363
- ) || [];
5679
+ const [onProgress, flush] =
5680
+ (onDownloadProgress &&
5681
+ progressEventDecorator(
5682
+ responseContentLength,
5683
+ progressEventReducer(asyncDecorator(onDownloadProgress), true)
5684
+ )) ||
5685
+ [];
5364
5686
 
5365
5687
  response = new Response(
5366
5688
  trackStream(response.body, DEFAULT_CHUNK_SIZE, onProgress, () => {
@@ -5373,7 +5695,10 @@ const factory = (env) => {
5373
5695
 
5374
5696
  responseType = responseType || 'text';
5375
5697
 
5376
- let responseData = await resolvers[utils.findKey(resolvers, responseType) || 'text'](response, config);
5698
+ let responseData = await resolvers[utils.findKey(resolvers, responseType) || 'text'](
5699
+ response,
5700
+ config
5701
+ );
5377
5702
 
5378
5703
  !isStreamResponse && unsubscribe && unsubscribe();
5379
5704
 
@@ -5384,43 +5709,50 @@ const factory = (env) => {
5384
5709
  status: response.status,
5385
5710
  statusText: response.statusText,
5386
5711
  config,
5387
- request
5388
- })
5389
- })
5712
+ request,
5713
+ });
5714
+ });
5390
5715
  } catch (err) {
5391
5716
  unsubscribe && unsubscribe();
5392
5717
 
5393
5718
  if (err && err.name === 'TypeError' && /Load failed|fetch/i.test(err.message)) {
5394
5719
  throw Object.assign(
5395
- new core_AxiosError('Network Error', core_AxiosError.ERR_NETWORK, config, request, err && err.response),
5720
+ new core_AxiosError(
5721
+ 'Network Error',
5722
+ core_AxiosError.ERR_NETWORK,
5723
+ config,
5724
+ request,
5725
+ err && err.response
5726
+ ),
5396
5727
  {
5397
- cause: err.cause || err
5728
+ cause: err.cause || err,
5398
5729
  }
5399
- )
5730
+ );
5400
5731
  }
5401
5732
 
5402
5733
  throw core_AxiosError.from(err, err && err.code, config, request, err && err.response);
5403
5734
  }
5404
- }
5405
- }
5735
+ };
5736
+ };
5406
5737
 
5407
5738
  const seedCache = new Map();
5408
5739
 
5409
5740
  const getFetch = (config) => {
5410
5741
  let env = (config && config.env) || {};
5411
- const {fetch, Request, Response} = env;
5412
- const seeds = [
5413
- Request, Response, fetch
5414
- ];
5742
+ const { fetch, Request, Response } = env;
5743
+ const seeds = [Request, Response, fetch];
5415
5744
 
5416
- let len = seeds.length, i = len,
5417
- seed, target, map = seedCache;
5745
+ let len = seeds.length,
5746
+ i = len,
5747
+ seed,
5748
+ target,
5749
+ map = seedCache;
5418
5750
 
5419
5751
  while (i--) {
5420
5752
  seed = seeds[i];
5421
5753
  target = map.get(seed);
5422
5754
 
5423
- target === undefined && map.set(seed, target = (i ? new Map() : factory(env)))
5755
+ target === undefined && map.set(seed, (target = i ? new Map() : factory(env)));
5424
5756
 
5425
5757
  map = target;
5426
5758
  }
@@ -5445,7 +5777,7 @@ const adapter = getFetch();
5445
5777
  * - `http` for Node.js
5446
5778
  * - `xhr` for browsers
5447
5779
  * - `fetch` for fetch API-based requests
5448
- *
5780
+ *
5449
5781
  * @type {Object<string, Function|Object>}
5450
5782
  */
5451
5783
  const knownAdapters = {
@@ -5453,7 +5785,7 @@ const knownAdapters = {
5453
5785
  xhr: xhr,
5454
5786
  fetch: {
5455
5787
  get: getFetch,
5456
- }
5788
+ },
5457
5789
  };
5458
5790
 
5459
5791
  // Assign adapter names for easier debugging and identification
@@ -5470,7 +5802,7 @@ utils.forEach(knownAdapters, (fn, value) => {
5470
5802
 
5471
5803
  /**
5472
5804
  * Render a rejection reason string for unknown or unsupported adapters
5473
- *
5805
+ *
5474
5806
  * @param {string} reason
5475
5807
  * @returns {string}
5476
5808
  */
@@ -5478,17 +5810,18 @@ const renderReason = (reason) => `- ${reason}`;
5478
5810
 
5479
5811
  /**
5480
5812
  * Check if the adapter is resolved (function, null, or false)
5481
- *
5813
+ *
5482
5814
  * @param {Function|null|false} adapter
5483
5815
  * @returns {boolean}
5484
5816
  */
5485
- const isResolvedHandle = (adapter) => utils.isFunction(adapter) || adapter === null || adapter === false;
5817
+ const isResolvedHandle = (adapter) =>
5818
+ utils.isFunction(adapter) || adapter === null || adapter === false;
5486
5819
 
5487
5820
  /**
5488
5821
  * Get the first suitable adapter from the provided list.
5489
5822
  * Tries each adapter in order until a supported one is found.
5490
5823
  * Throws an AxiosError if no adapter is suitable.
5491
- *
5824
+ *
5492
5825
  * @param {Array<string|Function>|string|Function} adapters - Adapter(s) by name or function.
5493
5826
  * @param {Object} config - Axios request configuration
5494
5827
  * @throws {AxiosError} If no suitable adapter is available
@@ -5525,14 +5858,17 @@ function getAdapter(adapters, config) {
5525
5858
  }
5526
5859
 
5527
5860
  if (!adapter) {
5528
- const reasons = Object.entries(rejectedReasons)
5529
- .map(([id, state]) => `adapter ${id} ` +
5861
+ const reasons = Object.entries(rejectedReasons).map(
5862
+ ([id, state]) =>
5863
+ `adapter ${id} ` +
5530
5864
  (state === false ? 'is not supported by the environment' : 'is not available in the build')
5531
- );
5865
+ );
5532
5866
 
5533
- let s = length ?
5534
- (reasons.length > 1 ? 'since :\n' + reasons.map(renderReason).join('\n') : ' ' + renderReason(reasons[0])) :
5535
- 'as no adapter specified';
5867
+ let s = length
5868
+ ? reasons.length > 1
5869
+ ? 'since :\n' + reasons.map(renderReason).join('\n')
5870
+ : ' ' + renderReason(reasons[0])
5871
+ : 'as no adapter specified';
5536
5872
 
5537
5873
  throw new core_AxiosError(
5538
5874
  `There is no suitable adapter to dispatch the request ` + s,
@@ -5557,7 +5893,7 @@ function getAdapter(adapters, config) {
5557
5893
  * Exposes all known adapters
5558
5894
  * @type {Object<string, Function|Object>}
5559
5895
  */
5560
- adapters: knownAdapters
5896
+ adapters: knownAdapters,
5561
5897
  });
5562
5898
 
5563
5899
  ;// ../../../node_modules/axios/lib/core/dispatchRequest.js
@@ -5600,10 +5936,7 @@ function dispatchRequest(config) {
5600
5936
  config.headers = core_AxiosHeaders.from(config.headers);
5601
5937
 
5602
5938
  // Transform request data
5603
- config.data = transformData.call(
5604
- config,
5605
- config.transformRequest
5606
- );
5939
+ config.data = transformData.call(config, config.transformRequest);
5607
5940
 
5608
5941
  if (['post', 'put', 'patch'].indexOf(config.method) !== -1) {
5609
5942
  config.headers.setContentType('application/x-www-form-urlencoded', false);
@@ -5611,40 +5944,39 @@ function dispatchRequest(config) {
5611
5944
 
5612
5945
  const adapter = adapters.getAdapter(config.adapter || lib_defaults.adapter, config);
5613
5946
 
5614
- return adapter(config).then(function onAdapterResolution(response) {
5615
- throwIfCancellationRequested(config);
5616
-
5617
- // Transform response data
5618
- response.data = transformData.call(
5619
- config,
5620
- config.transformResponse,
5621
- response
5622
- );
5623
-
5624
- response.headers = core_AxiosHeaders.from(response.headers);
5625
-
5626
- return response;
5627
- }, function onAdapterRejection(reason) {
5628
- if (!isCancel(reason)) {
5947
+ return adapter(config).then(
5948
+ function onAdapterResolution(response) {
5629
5949
  throwIfCancellationRequested(config);
5630
5950
 
5631
5951
  // Transform response data
5632
- if (reason && reason.response) {
5633
- reason.response.data = transformData.call(
5634
- config,
5635
- config.transformResponse,
5636
- reason.response
5637
- );
5638
- reason.response.headers = core_AxiosHeaders.from(reason.response.headers);
5952
+ response.data = transformData.call(config, config.transformResponse, response);
5953
+
5954
+ response.headers = core_AxiosHeaders.from(response.headers);
5955
+
5956
+ return response;
5957
+ },
5958
+ function onAdapterRejection(reason) {
5959
+ if (!isCancel(reason)) {
5960
+ throwIfCancellationRequested(config);
5961
+
5962
+ // Transform response data
5963
+ if (reason && reason.response) {
5964
+ reason.response.data = transformData.call(
5965
+ config,
5966
+ config.transformResponse,
5967
+ reason.response
5968
+ );
5969
+ reason.response.headers = core_AxiosHeaders.from(reason.response.headers);
5970
+ }
5639
5971
  }
5640
- }
5641
5972
 
5642
- return Promise.reject(reason);
5643
- });
5973
+ return Promise.reject(reason);
5974
+ }
5975
+ );
5644
5976
  }
5645
5977
 
5646
5978
  ;// ../../../node_modules/axios/lib/env/data.js
5647
- const VERSION = "1.13.5";
5979
+ const VERSION = "1.15.2";
5648
5980
  ;// ../../../node_modules/axios/lib/helpers/validator.js
5649
5981
 
5650
5982
 
@@ -5673,7 +6005,15 @@ const deprecatedWarnings = {};
5673
6005
  */
5674
6006
  validators.transitional = function transitional(validator, version, message) {
5675
6007
  function formatMessage(opt, desc) {
5676
- return '[Axios v' + VERSION + '] Transitional option \'' + opt + '\'' + desc + (message ? '. ' + message : '');
6008
+ return (
6009
+ '[Axios v' +
6010
+ VERSION +
6011
+ "] Transitional option '" +
6012
+ opt +
6013
+ "'" +
6014
+ desc +
6015
+ (message ? '. ' + message : '')
6016
+ );
5677
6017
  }
5678
6018
 
5679
6019
  // eslint-disable-next-line func-names
@@ -5705,7 +6045,7 @@ validators.spelling = function spelling(correctSpelling) {
5705
6045
  // eslint-disable-next-line no-console
5706
6046
  console.warn(`${opt} is likely a misspelling of ${correctSpelling}`);
5707
6047
  return true;
5708
- }
6048
+ };
5709
6049
  };
5710
6050
 
5711
6051
  /**
@@ -5726,12 +6066,17 @@ function assertOptions(options, schema, allowUnknown) {
5726
6066
  let i = keys.length;
5727
6067
  while (i-- > 0) {
5728
6068
  const opt = keys[i];
5729
- const validator = schema[opt];
6069
+ // Use hasOwnProperty so a polluted Object.prototype.<opt> cannot supply
6070
+ // a non-function validator and cause a TypeError. See GHSA-q8qp-cvcw-x6jj.
6071
+ const validator = Object.prototype.hasOwnProperty.call(schema, opt) ? schema[opt] : undefined;
5730
6072
  if (validator) {
5731
6073
  const value = options[opt];
5732
6074
  const result = value === undefined || validator(value, opt, options);
5733
6075
  if (result !== true) {
5734
- throw new core_AxiosError('option ' + opt + ' must be ' + result, core_AxiosError.ERR_BAD_OPTION_VALUE);
6076
+ throw new core_AxiosError(
6077
+ 'option ' + opt + ' must be ' + result,
6078
+ core_AxiosError.ERR_BAD_OPTION_VALUE
6079
+ );
5735
6080
  }
5736
6081
  continue;
5737
6082
  }
@@ -5743,7 +6088,7 @@ function assertOptions(options, schema, allowUnknown) {
5743
6088
 
5744
6089
  /* harmony default export */ const validator = ({
5745
6090
  assertOptions,
5746
- validators
6091
+ validators,
5747
6092
  });
5748
6093
 
5749
6094
  ;// ../../../node_modules/axios/lib/core/Axios.js
@@ -5773,7 +6118,7 @@ class Axios {
5773
6118
  this.defaults = instanceConfig || {};
5774
6119
  this.interceptors = {
5775
6120
  request: new core_InterceptorManager(),
5776
- response: new core_InterceptorManager()
6121
+ response: new core_InterceptorManager(),
5777
6122
  };
5778
6123
  }
5779
6124
 
@@ -5795,13 +6140,29 @@ class Axios {
5795
6140
  Error.captureStackTrace ? Error.captureStackTrace(dummy) : (dummy = new Error());
5796
6141
 
5797
6142
  // slice off the Error: ... line
5798
- const stack = dummy.stack ? dummy.stack.replace(/^.+\n/, '') : '';
6143
+ const stack = (() => {
6144
+ if (!dummy.stack) {
6145
+ return '';
6146
+ }
6147
+
6148
+ const firstNewlineIndex = dummy.stack.indexOf('\n');
6149
+
6150
+ return firstNewlineIndex === -1 ? '' : dummy.stack.slice(firstNewlineIndex + 1);
6151
+ })();
5799
6152
  try {
5800
6153
  if (!err.stack) {
5801
6154
  err.stack = stack;
5802
6155
  // match without the 2 top stack lines
5803
- } else if (stack && !String(err.stack).endsWith(stack.replace(/^.+\n.+\n/, ''))) {
5804
- err.stack += '\n' + stack
6156
+ } else if (stack) {
6157
+ const firstNewlineIndex = stack.indexOf('\n');
6158
+ const secondNewlineIndex =
6159
+ firstNewlineIndex === -1 ? -1 : stack.indexOf('\n', firstNewlineIndex + 1);
6160
+ const stackWithoutTwoTopLines =
6161
+ secondNewlineIndex === -1 ? '' : stack.slice(secondNewlineIndex + 1);
6162
+
6163
+ if (!String(err.stack).endsWith(stackWithoutTwoTopLines)) {
6164
+ err.stack += '\n' + stack;
6165
+ }
5805
6166
  }
5806
6167
  } catch (e) {
5807
6168
  // ignore the case where "stack" is an un-writable property
@@ -5824,27 +6185,35 @@ class Axios {
5824
6185
 
5825
6186
  config = mergeConfig(this.defaults, config);
5826
6187
 
5827
- const {transitional, paramsSerializer, headers} = config;
6188
+ const { transitional, paramsSerializer, headers } = config;
5828
6189
 
5829
6190
  if (transitional !== undefined) {
5830
- validator.assertOptions(transitional, {
5831
- silentJSONParsing: Axios_validators.transitional(Axios_validators.boolean),
5832
- forcedJSONParsing: Axios_validators.transitional(Axios_validators.boolean),
5833
- clarifyTimeoutError: Axios_validators.transitional(Axios_validators.boolean),
5834
- legacyInterceptorReqResOrdering: Axios_validators.transitional(Axios_validators.boolean)
5835
- }, false);
6191
+ validator.assertOptions(
6192
+ transitional,
6193
+ {
6194
+ silentJSONParsing: Axios_validators.transitional(Axios_validators.boolean),
6195
+ forcedJSONParsing: Axios_validators.transitional(Axios_validators.boolean),
6196
+ clarifyTimeoutError: Axios_validators.transitional(Axios_validators.boolean),
6197
+ legacyInterceptorReqResOrdering: Axios_validators.transitional(Axios_validators.boolean),
6198
+ },
6199
+ false
6200
+ );
5836
6201
  }
5837
6202
 
5838
6203
  if (paramsSerializer != null) {
5839
6204
  if (utils.isFunction(paramsSerializer)) {
5840
6205
  config.paramsSerializer = {
5841
- serialize: paramsSerializer
5842
- }
6206
+ serialize: paramsSerializer,
6207
+ };
5843
6208
  } else {
5844
- validator.assertOptions(paramsSerializer, {
5845
- encode: Axios_validators.function,
5846
- serialize: Axios_validators.function
5847
- }, true);
6209
+ validator.assertOptions(
6210
+ paramsSerializer,
6211
+ {
6212
+ encode: Axios_validators.function,
6213
+ serialize: Axios_validators.function,
6214
+ },
6215
+ true
6216
+ );
5848
6217
  }
5849
6218
  }
5850
6219
 
@@ -5857,26 +6226,25 @@ class Axios {
5857
6226
  config.allowAbsoluteUrls = true;
5858
6227
  }
5859
6228
 
5860
- validator.assertOptions(config, {
5861
- baseUrl: Axios_validators.spelling('baseURL'),
5862
- withXsrfToken: Axios_validators.spelling('withXSRFToken')
5863
- }, true);
6229
+ validator.assertOptions(
6230
+ config,
6231
+ {
6232
+ baseUrl: Axios_validators.spelling('baseURL'),
6233
+ withXsrfToken: Axios_validators.spelling('withXSRFToken'),
6234
+ },
6235
+ true
6236
+ );
5864
6237
 
5865
6238
  // Set config.method
5866
6239
  config.method = (config.method || this.defaults.method || 'get').toLowerCase();
5867
6240
 
5868
6241
  // Flatten headers
5869
- let contextHeaders = headers && utils.merge(
5870
- headers.common,
5871
- headers[config.method]
5872
- );
6242
+ let contextHeaders = headers && utils.merge(headers.common, headers[config.method]);
5873
6243
 
5874
- headers && utils.forEach(
5875
- ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'],
5876
- (method) => {
6244
+ headers &&
6245
+ utils.forEach(['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], (method) => {
5877
6246
  delete headers[method];
5878
- }
5879
- );
6247
+ });
5880
6248
 
5881
6249
  config.headers = core_AxiosHeaders.concat(contextHeaders, headers);
5882
6250
 
@@ -5891,7 +6259,8 @@ class Axios {
5891
6259
  synchronousRequestInterceptors = synchronousRequestInterceptors && interceptor.synchronous;
5892
6260
 
5893
6261
  const transitional = config.transitional || defaults_transitional;
5894
- const legacyInterceptorReqResOrdering = transitional && transitional.legacyInterceptorReqResOrdering;
6262
+ const legacyInterceptorReqResOrdering =
6263
+ transitional && transitional.legacyInterceptorReqResOrdering;
5895
6264
 
5896
6265
  if (legacyInterceptorReqResOrdering) {
5897
6266
  requestInterceptorChain.unshift(interceptor.fulfilled, interceptor.rejected);
@@ -5965,28 +6334,32 @@ class Axios {
5965
6334
  // Provide aliases for supported request methods
5966
6335
  utils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {
5967
6336
  /*eslint func-names:0*/
5968
- Axios.prototype[method] = function(url, config) {
5969
- return this.request(mergeConfig(config || {}, {
5970
- method,
5971
- url,
5972
- data: (config || {}).data
5973
- }));
6337
+ Axios.prototype[method] = function (url, config) {
6338
+ return this.request(
6339
+ mergeConfig(config || {}, {
6340
+ method,
6341
+ url,
6342
+ data: (config || {}).data,
6343
+ })
6344
+ );
5974
6345
  };
5975
6346
  });
5976
6347
 
5977
6348
  utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {
5978
- /*eslint func-names:0*/
5979
-
5980
6349
  function generateHTTPMethod(isForm) {
5981
6350
  return function httpMethod(url, data, config) {
5982
- return this.request(mergeConfig(config || {}, {
5983
- method,
5984
- headers: isForm ? {
5985
- 'Content-Type': 'multipart/form-data'
5986
- } : {},
5987
- url,
5988
- data
5989
- }));
6351
+ return this.request(
6352
+ mergeConfig(config || {}, {
6353
+ method,
6354
+ headers: isForm
6355
+ ? {
6356
+ 'Content-Type': 'multipart/form-data',
6357
+ }
6358
+ : {},
6359
+ url,
6360
+ data,
6361
+ })
6362
+ );
5990
6363
  };
5991
6364
  }
5992
6365
 
@@ -6024,7 +6397,7 @@ class CancelToken {
6024
6397
  const token = this;
6025
6398
 
6026
6399
  // eslint-disable-next-line func-names
6027
- this.promise.then(cancel => {
6400
+ this.promise.then((cancel) => {
6028
6401
  if (!token._listeners) return;
6029
6402
 
6030
6403
  let i = token._listeners.length;
@@ -6036,10 +6409,10 @@ class CancelToken {
6036
6409
  });
6037
6410
 
6038
6411
  // eslint-disable-next-line func-names
6039
- this.promise.then = onfulfilled => {
6412
+ this.promise.then = (onfulfilled) => {
6040
6413
  let _resolve;
6041
6414
  // eslint-disable-next-line func-names
6042
- const promise = new Promise(resolve => {
6415
+ const promise = new Promise((resolve) => {
6043
6416
  token.subscribe(resolve);
6044
6417
  _resolve = resolve;
6045
6418
  }).then(onfulfilled);
@@ -6127,7 +6500,7 @@ class CancelToken {
6127
6500
  });
6128
6501
  return {
6129
6502
  token,
6130
- cancel
6503
+ cancel,
6131
6504
  };
6132
6505
  }
6133
6506
  }
@@ -6177,7 +6550,7 @@ function spread(callback) {
6177
6550
  * @returns {boolean} True if the payload is an error thrown by Axios, otherwise false
6178
6551
  */
6179
6552
  function isAxiosError(payload) {
6180
- return utils.isObject(payload) && (payload.isAxiosError === true);
6553
+ return utils.isObject(payload) && payload.isAxiosError === true;
6181
6554
  }
6182
6555
 
6183
6556
  ;// ../../../node_modules/axios/lib/helpers/HttpStatusCode.js
@@ -6292,10 +6665,10 @@ function createInstance(defaultConfig) {
6292
6665
  const instance = bind(core_Axios.prototype.request, context);
6293
6666
 
6294
6667
  // Copy axios.prototype to instance
6295
- utils.extend(instance, core_Axios.prototype, context, {allOwnKeys: true});
6668
+ utils.extend(instance, core_Axios.prototype, context, { allOwnKeys: true });
6296
6669
 
6297
6670
  // Copy context to instance
6298
- utils.extend(instance, context, null, {allOwnKeys: true});
6671
+ utils.extend(instance, context, null, { allOwnKeys: true });
6299
6672
 
6300
6673
  // Factory for creating new instances
6301
6674
  instance.create = function create(instanceConfig) {
@@ -6339,7 +6712,7 @@ axios.mergeConfig = mergeConfig;
6339
6712
 
6340
6713
  axios.AxiosHeaders = core_AxiosHeaders;
6341
6714
 
6342
- axios.formToJSON = thing => helpers_formDataToJSON(utils.isHTMLForm(thing) ? new FormData(thing) : thing);
6715
+ axios.formToJSON = (thing) => helpers_formDataToJSON(utils.isHTMLForm(thing) ? new FormData(thing) : thing);
6343
6716
 
6344
6717
  axios.getAdapter = adapters.getAdapter;
6345
6718
 
@@ -6372,16 +6745,16 @@ const {
6372
6745
  HttpStatusCode: axios_HttpStatusCode,
6373
6746
  formToJSON,
6374
6747
  getAdapter: axios_getAdapter,
6375
- mergeConfig: axios_mergeConfig
6748
+ mergeConfig: axios_mergeConfig,
6376
6749
  } = lib_axios;
6377
6750
 
6378
6751
 
6379
6752
 
6380
6753
 
6381
- /***/ }),
6754
+ /***/ },
6382
6755
 
6383
- /***/ 47911:
6384
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
6756
+ /***/ 47911
6757
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
6385
6758
 
6386
6759
  "use strict";
6387
6760
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
@@ -6464,10 +6837,10 @@ function bufferToTypedArray(wasmType, buffer) {
6464
6837
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (bufferToTypedArray);
6465
6838
  //# sourceMappingURL=buffer-to-typed-array.js.map
6466
6839
 
6467
- /***/ }),
6840
+ /***/ },
6468
6841
 
6469
- /***/ 46619:
6470
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
6842
+ /***/ 46619
6843
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
6471
6844
 
6472
6845
  "use strict";
6473
6846
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
@@ -6510,10 +6883,10 @@ function getTransferable(data, noCopy) {
6510
6883
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (getTransferables);
6511
6884
  //# sourceMappingURL=get-transferables.js.map
6512
6885
 
6513
- /***/ }),
6886
+ /***/ },
6514
6887
 
6515
- /***/ 74112:
6516
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
6888
+ /***/ 74112
6889
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
6517
6890
 
6518
6891
  "use strict";
6519
6892
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
@@ -6527,10 +6900,10 @@ const FloatTypes = {
6527
6900
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (FloatTypes);
6528
6901
  //# sourceMappingURL=float-types.js.map
6529
6902
 
6530
- /***/ }),
6903
+ /***/ },
6531
6904
 
6532
- /***/ 44835:
6533
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
6905
+ /***/ 44835
6906
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
6534
6907
 
6535
6908
  "use strict";
6536
6909
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
@@ -6553,10 +6926,10 @@ const IntTypes = {
6553
6926
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (IntTypes);
6554
6927
  //# sourceMappingURL=int-types.js.map
6555
6928
 
6556
- /***/ }),
6929
+ /***/ },
6557
6930
 
6558
- /***/ 16881:
6559
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
6931
+ /***/ 16881
6932
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
6560
6933
 
6561
6934
  "use strict";
6562
6935
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
@@ -6575,10 +6948,10 @@ const InterfaceTypes = {
6575
6948
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (InterfaceTypes);
6576
6949
  //# sourceMappingURL=interface-types.js.map
6577
6950
 
6578
- /***/ }),
6951
+ /***/ },
6579
6952
 
6580
- /***/ 27295:
6581
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
6953
+ /***/ 27295
6954
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
6582
6955
 
6583
6956
  "use strict";
6584
6957
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
@@ -6593,10 +6966,10 @@ function imageTransferables(image) {
6593
6966
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (imageTransferables);
6594
6967
  //# sourceMappingURL=image-transferables.js.map
6595
6968
 
6596
- /***/ }),
6969
+ /***/ },
6597
6970
 
6598
- /***/ 50295:
6599
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
6971
+ /***/ 50295
6972
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
6600
6973
 
6601
6974
  "use strict";
6602
6975
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
@@ -6613,10 +6986,10 @@ function meshTransferables(mesh) {
6613
6986
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (meshTransferables);
6614
6987
  //# sourceMappingURL=mesh-transferables.js.map
6615
6988
 
6616
- /***/ }),
6989
+ /***/ },
6617
6990
 
6618
- /***/ 3099:
6619
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
6991
+ /***/ 3099
6992
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
6620
6993
 
6621
6994
  "use strict";
6622
6995
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
@@ -6636,10 +7009,10 @@ function polyDataTransferables(polyData) {
6636
7009
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (polyDataTransferables);
6637
7010
  //# sourceMappingURL=poly-data-transferables.js.map
6638
7011
 
6639
- /***/ }),
7012
+ /***/ },
6640
7013
 
6641
- /***/ 8792:
6642
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
7014
+ /***/ 8792
7015
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
6643
7016
 
6644
7017
  "use strict";
6645
7018
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
@@ -6996,6 +7369,6 @@ function runPipelineEmscripten(pipelineModule, args, outputs, inputs) {
6996
7369
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (runPipelineEmscripten);
6997
7370
  //# sourceMappingURL=run-pipeline-emscripten.js.map
6998
7371
 
6999
- /***/ })
7372
+ /***/ }
7000
7373
 
7001
7374
  }]);