@bigbinary/neeto-audit-frontend 2.3.1 → 2.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js
CHANGED
|
@@ -10,13 +10,14 @@ import require$$4 from 'process';
|
|
|
10
10
|
import { readFile, mkdir, lstat, writeFile } from 'fs/promises';
|
|
11
11
|
import require$$0$3 from 'assert';
|
|
12
12
|
import require$$1$1 from 'tty';
|
|
13
|
-
import
|
|
13
|
+
import util$3 from 'util';
|
|
14
14
|
import require$$0$4 from 'os';
|
|
15
15
|
import stream, { Readable } from 'stream';
|
|
16
16
|
import require$$3$1 from 'http';
|
|
17
17
|
import require$$4$1 from 'https';
|
|
18
18
|
import require$$0$5 from 'url';
|
|
19
19
|
import require$$8 from 'crypto';
|
|
20
|
+
import http2 from 'http2';
|
|
20
21
|
import zlib from 'zlib';
|
|
21
22
|
|
|
22
23
|
const ANSI_BACKGROUND_OFFSET = 10;
|
|
@@ -2816,12 +2817,12 @@ function _iterableToArrayLimit(r, l) {
|
|
|
2816
2817
|
i,
|
|
2817
2818
|
u,
|
|
2818
2819
|
a = [],
|
|
2819
|
-
f =
|
|
2820
|
-
o =
|
|
2820
|
+
f = true,
|
|
2821
|
+
o = false;
|
|
2821
2822
|
try {
|
|
2822
2823
|
if (i = (t = t.call(r)).next, 0 === l) ; else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
|
|
2823
2824
|
} catch (r) {
|
|
2824
|
-
o =
|
|
2825
|
+
o = true, n = r;
|
|
2825
2826
|
} finally {
|
|
2826
2827
|
try {
|
|
2827
2828
|
if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return;
|
|
@@ -2921,7 +2922,7 @@ function _defineProperty(obj, key, value) {
|
|
|
2921
2922
|
}
|
|
2922
2923
|
|
|
2923
2924
|
function ownKeys$1(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
2924
|
-
function _objectSpread$1(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$1(Object(t),
|
|
2925
|
+
function _objectSpread$1(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$1(Object(t), true).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$1(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
2925
2926
|
// src/utils/env.ts
|
|
2926
2927
|
var NOTHING = Symbol["for"]("immer-nothing");
|
|
2927
2928
|
var DRAFTABLE = Symbol["for"]("immer-draftable");
|
|
@@ -6929,7 +6930,7 @@ function incrementNodeInspectorPort(args) {
|
|
|
6929
6930
|
|
|
6930
6931
|
command.Command = Command$1;
|
|
6931
6932
|
|
|
6932
|
-
(function (module, exports) {
|
|
6933
|
+
(function (module, exports$1) {
|
|
6933
6934
|
const { Argument } = argument;
|
|
6934
6935
|
const { Command } = command;
|
|
6935
6936
|
const { CommanderError, InvalidArgumentError } = error;
|
|
@@ -6940,22 +6941,22 @@ command.Command = Command$1;
|
|
|
6940
6941
|
* Expose the root command.
|
|
6941
6942
|
*/
|
|
6942
6943
|
|
|
6943
|
-
exports = module.exports = new Command();
|
|
6944
|
-
exports.program = exports; // More explicit access to global command.
|
|
6944
|
+
exports$1 = module.exports = new Command();
|
|
6945
|
+
exports$1.program = exports$1; // More explicit access to global command.
|
|
6945
6946
|
// createArgument, createCommand, and createOption are implicitly available as they are methods on program.
|
|
6946
6947
|
|
|
6947
6948
|
/**
|
|
6948
6949
|
* Expose classes
|
|
6949
6950
|
*/
|
|
6950
6951
|
|
|
6951
|
-
exports.Command = Command;
|
|
6952
|
-
exports.Option = Option;
|
|
6953
|
-
exports.Argument = Argument;
|
|
6954
|
-
exports.Help = Help;
|
|
6952
|
+
exports$1.Command = Command;
|
|
6953
|
+
exports$1.Option = Option;
|
|
6954
|
+
exports$1.Argument = Argument;
|
|
6955
|
+
exports$1.Help = Help;
|
|
6955
6956
|
|
|
6956
|
-
exports.CommanderError = CommanderError;
|
|
6957
|
-
exports.InvalidArgumentError = InvalidArgumentError;
|
|
6958
|
-
exports.InvalidOptionArgumentError = InvalidArgumentError; // Deprecated
|
|
6957
|
+
exports$1.CommanderError = CommanderError;
|
|
6958
|
+
exports$1.InvalidArgumentError = InvalidArgumentError;
|
|
6959
|
+
exports$1.InvalidOptionArgumentError = InvalidArgumentError; // Deprecated
|
|
6959
6960
|
} (commander$1, commander$1.exports));
|
|
6960
6961
|
|
|
6961
6962
|
var commanderExports = commander$1.exports;
|
|
@@ -10481,17 +10482,17 @@ var hasRequiredBrowser;
|
|
|
10481
10482
|
function requireBrowser () {
|
|
10482
10483
|
if (hasRequiredBrowser) return browser.exports;
|
|
10483
10484
|
hasRequiredBrowser = 1;
|
|
10484
|
-
(function (module, exports) {
|
|
10485
|
+
(function (module, exports$1) {
|
|
10485
10486
|
/**
|
|
10486
10487
|
* This is the web browser implementation of `debug()`.
|
|
10487
10488
|
*/
|
|
10488
10489
|
|
|
10489
|
-
exports.formatArgs = formatArgs;
|
|
10490
|
-
exports.save = save;
|
|
10491
|
-
exports.load = load;
|
|
10492
|
-
exports.useColors = useColors;
|
|
10493
|
-
exports.storage = localstorage();
|
|
10494
|
-
exports.destroy = (() => {
|
|
10490
|
+
exports$1.formatArgs = formatArgs;
|
|
10491
|
+
exports$1.save = save;
|
|
10492
|
+
exports$1.load = load;
|
|
10493
|
+
exports$1.useColors = useColors;
|
|
10494
|
+
exports$1.storage = localstorage();
|
|
10495
|
+
exports$1.destroy = (() => {
|
|
10495
10496
|
let warned = false;
|
|
10496
10497
|
|
|
10497
10498
|
return () => {
|
|
@@ -10506,7 +10507,7 @@ function requireBrowser () {
|
|
|
10506
10507
|
* Colors.
|
|
10507
10508
|
*/
|
|
10508
10509
|
|
|
10509
|
-
exports.colors = [
|
|
10510
|
+
exports$1.colors = [
|
|
10510
10511
|
'#0000CC',
|
|
10511
10512
|
'#0000FF',
|
|
10512
10513
|
'#0033CC',
|
|
@@ -10668,7 +10669,7 @@ function requireBrowser () {
|
|
|
10668
10669
|
*
|
|
10669
10670
|
* @api public
|
|
10670
10671
|
*/
|
|
10671
|
-
exports.log = console.debug || console.log || (() => {});
|
|
10672
|
+
exports$1.log = console.debug || console.log || (() => {});
|
|
10672
10673
|
|
|
10673
10674
|
/**
|
|
10674
10675
|
* Save `namespaces`.
|
|
@@ -10679,9 +10680,9 @@ function requireBrowser () {
|
|
|
10679
10680
|
function save(namespaces) {
|
|
10680
10681
|
try {
|
|
10681
10682
|
if (namespaces) {
|
|
10682
|
-
exports.storage.setItem('debug', namespaces);
|
|
10683
|
+
exports$1.storage.setItem('debug', namespaces);
|
|
10683
10684
|
} else {
|
|
10684
|
-
exports.storage.removeItem('debug');
|
|
10685
|
+
exports$1.storage.removeItem('debug');
|
|
10685
10686
|
}
|
|
10686
10687
|
} catch (error) {
|
|
10687
10688
|
// Swallow
|
|
@@ -10698,7 +10699,7 @@ function requireBrowser () {
|
|
|
10698
10699
|
function load() {
|
|
10699
10700
|
let r;
|
|
10700
10701
|
try {
|
|
10701
|
-
r = exports.storage.getItem('debug');
|
|
10702
|
+
r = exports$1.storage.getItem('debug');
|
|
10702
10703
|
} catch (error) {
|
|
10703
10704
|
// Swallow
|
|
10704
10705
|
// XXX (@Qix-) should we be logging these?
|
|
@@ -10734,7 +10735,7 @@ function requireBrowser () {
|
|
|
10734
10735
|
}
|
|
10735
10736
|
}
|
|
10736
10737
|
|
|
10737
|
-
module.exports = requireCommon()(exports);
|
|
10738
|
+
module.exports = requireCommon()(exports$1);
|
|
10738
10739
|
|
|
10739
10740
|
const {formatters} = module.exports;
|
|
10740
10741
|
|
|
@@ -10940,21 +10941,21 @@ var hasRequiredNode;
|
|
|
10940
10941
|
function requireNode () {
|
|
10941
10942
|
if (hasRequiredNode) return node.exports;
|
|
10942
10943
|
hasRequiredNode = 1;
|
|
10943
|
-
(function (module, exports) {
|
|
10944
|
+
(function (module, exports$1) {
|
|
10944
10945
|
const tty = require$$1$1;
|
|
10945
|
-
const util =
|
|
10946
|
+
const util = util$3;
|
|
10946
10947
|
|
|
10947
10948
|
/**
|
|
10948
10949
|
* This is the Node.js implementation of `debug()`.
|
|
10949
10950
|
*/
|
|
10950
10951
|
|
|
10951
|
-
exports.init = init;
|
|
10952
|
-
exports.log = log;
|
|
10953
|
-
exports.formatArgs = formatArgs;
|
|
10954
|
-
exports.save = save;
|
|
10955
|
-
exports.load = load;
|
|
10956
|
-
exports.useColors = useColors;
|
|
10957
|
-
exports.destroy = util.deprecate(
|
|
10952
|
+
exports$1.init = init;
|
|
10953
|
+
exports$1.log = log;
|
|
10954
|
+
exports$1.formatArgs = formatArgs;
|
|
10955
|
+
exports$1.save = save;
|
|
10956
|
+
exports$1.load = load;
|
|
10957
|
+
exports$1.useColors = useColors;
|
|
10958
|
+
exports$1.destroy = util.deprecate(
|
|
10958
10959
|
() => {},
|
|
10959
10960
|
'Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.'
|
|
10960
10961
|
);
|
|
@@ -10963,7 +10964,7 @@ function requireNode () {
|
|
|
10963
10964
|
* Colors.
|
|
10964
10965
|
*/
|
|
10965
10966
|
|
|
10966
|
-
exports.colors = [6, 2, 3, 4, 5, 1];
|
|
10967
|
+
exports$1.colors = [6, 2, 3, 4, 5, 1];
|
|
10967
10968
|
|
|
10968
10969
|
try {
|
|
10969
10970
|
// Optional dependency (as in, doesn't need to be installed, NOT like optionalDependencies in package.json)
|
|
@@ -10971,7 +10972,7 @@ function requireNode () {
|
|
|
10971
10972
|
const supportsColor = requireSupportsColor();
|
|
10972
10973
|
|
|
10973
10974
|
if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
|
|
10974
|
-
exports.colors = [
|
|
10975
|
+
exports$1.colors = [
|
|
10975
10976
|
20,
|
|
10976
10977
|
21,
|
|
10977
10978
|
26,
|
|
@@ -11060,7 +11061,7 @@ function requireNode () {
|
|
|
11060
11061
|
* $ DEBUG_COLORS=no DEBUG_DEPTH=10 DEBUG_SHOW_HIDDEN=enabled node script.js
|
|
11061
11062
|
*/
|
|
11062
11063
|
|
|
11063
|
-
exports.inspectOpts = Object.keys(process.env).filter(key => {
|
|
11064
|
+
exports$1.inspectOpts = Object.keys(process.env).filter(key => {
|
|
11064
11065
|
return /^debug_/i.test(key);
|
|
11065
11066
|
}).reduce((obj, key) => {
|
|
11066
11067
|
// Camel-case
|
|
@@ -11092,8 +11093,8 @@ function requireNode () {
|
|
|
11092
11093
|
*/
|
|
11093
11094
|
|
|
11094
11095
|
function useColors() {
|
|
11095
|
-
return 'colors' in exports.inspectOpts ?
|
|
11096
|
-
Boolean(exports.inspectOpts.colors) :
|
|
11096
|
+
return 'colors' in exports$1.inspectOpts ?
|
|
11097
|
+
Boolean(exports$1.inspectOpts.colors) :
|
|
11097
11098
|
tty.isatty(process.stderr.fd);
|
|
11098
11099
|
}
|
|
11099
11100
|
|
|
@@ -11119,7 +11120,7 @@ function requireNode () {
|
|
|
11119
11120
|
}
|
|
11120
11121
|
|
|
11121
11122
|
function getDate() {
|
|
11122
|
-
if (exports.inspectOpts.hideDate) {
|
|
11123
|
+
if (exports$1.inspectOpts.hideDate) {
|
|
11123
11124
|
return '';
|
|
11124
11125
|
}
|
|
11125
11126
|
return new Date().toISOString() + ' ';
|
|
@@ -11170,13 +11171,13 @@ function requireNode () {
|
|
|
11170
11171
|
function init(debug) {
|
|
11171
11172
|
debug.inspectOpts = {};
|
|
11172
11173
|
|
|
11173
|
-
const keys = Object.keys(exports.inspectOpts);
|
|
11174
|
+
const keys = Object.keys(exports$1.inspectOpts);
|
|
11174
11175
|
for (let i = 0; i < keys.length; i++) {
|
|
11175
|
-
debug.inspectOpts[keys[i]] = exports.inspectOpts[keys[i]];
|
|
11176
|
+
debug.inspectOpts[keys[i]] = exports$1.inspectOpts[keys[i]];
|
|
11176
11177
|
}
|
|
11177
11178
|
}
|
|
11178
11179
|
|
|
11179
|
-
module.exports = requireCommon()(exports);
|
|
11180
|
+
module.exports = requireCommon()(exports$1);
|
|
11180
11181
|
|
|
11181
11182
|
const {formatters} = module.exports;
|
|
11182
11183
|
|
|
@@ -11218,11 +11219,11 @@ if (typeof process === 'undefined' || process.type === 'renderer' || process.bro
|
|
|
11218
11219
|
var srcExports = src.exports;
|
|
11219
11220
|
var debug$2 = /*@__PURE__*/getDefaultExportFromCjs(srcExports);
|
|
11220
11221
|
|
|
11221
|
-
(function (exports) {
|
|
11222
|
+
(function (exports$1) {
|
|
11222
11223
|
var __importDefault = (commonjsGlobal && commonjsGlobal.__importDefault) || function (mod) {
|
|
11223
11224
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11224
11225
|
};
|
|
11225
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11226
|
+
Object.defineProperty(exports$1, "__esModule", { value: true });
|
|
11226
11227
|
const fs_1 = require$$3;
|
|
11227
11228
|
const debug_1 = __importDefault(srcExports);
|
|
11228
11229
|
const log = debug_1.default('@kwsites/file-exists');
|
|
@@ -11256,30 +11257,30 @@ var debug$2 = /*@__PURE__*/getDefaultExportFromCjs(srcExports);
|
|
|
11256
11257
|
* @param {string} path The path to check
|
|
11257
11258
|
* @param {number} type One or both of the exported numeric constants
|
|
11258
11259
|
*/
|
|
11259
|
-
function exists(path, type = exports.READABLE) {
|
|
11260
|
-
return check(path, (type & exports.FILE) > 0, (type & exports.FOLDER) > 0);
|
|
11260
|
+
function exists(path, type = exports$1.READABLE) {
|
|
11261
|
+
return check(path, (type & exports$1.FILE) > 0, (type & exports$1.FOLDER) > 0);
|
|
11261
11262
|
}
|
|
11262
|
-
exports.exists = exists;
|
|
11263
|
+
exports$1.exists = exists;
|
|
11263
11264
|
/**
|
|
11264
11265
|
* Constant representing a file
|
|
11265
11266
|
*/
|
|
11266
|
-
exports.FILE = 1;
|
|
11267
|
+
exports$1.FILE = 1;
|
|
11267
11268
|
/**
|
|
11268
11269
|
* Constant representing a folder
|
|
11269
11270
|
*/
|
|
11270
|
-
exports.FOLDER = 2;
|
|
11271
|
+
exports$1.FOLDER = 2;
|
|
11271
11272
|
/**
|
|
11272
11273
|
* Constant representing either a file or a folder
|
|
11273
11274
|
*/
|
|
11274
|
-
exports.READABLE = exports.FILE + exports.FOLDER;
|
|
11275
|
+
exports$1.READABLE = exports$1.FILE + exports$1.FOLDER;
|
|
11275
11276
|
|
|
11276
11277
|
} (src$1));
|
|
11277
11278
|
|
|
11278
|
-
(function (exports) {
|
|
11279
|
+
(function (exports$1) {
|
|
11279
11280
|
function __export(m) {
|
|
11280
|
-
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
|
|
11281
|
+
for (var p in m) if (!exports$1.hasOwnProperty(p)) exports$1[p] = m[p];
|
|
11281
11282
|
}
|
|
11282
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11283
|
+
Object.defineProperty(exports$1, "__esModule", { value: true });
|
|
11283
11284
|
__export(src$1);
|
|
11284
11285
|
|
|
11285
11286
|
} (dist$1));
|
|
@@ -14731,7 +14732,7 @@ var init_tag = __esm({
|
|
|
14731
14732
|
|
|
14732
14733
|
// src/git.js
|
|
14733
14734
|
var require_git = __commonJS({
|
|
14734
|
-
"src/git.js"(exports, module) {
|
|
14735
|
+
"src/git.js"(exports$1, module) {
|
|
14735
14736
|
var { GitExecutor: GitExecutor2 } = (init_git_executor(), __toCommonJS(git_executor_exports));
|
|
14736
14737
|
var { SimpleGitApi: SimpleGitApi2 } = (init_simple_git_api(), __toCommonJS(simple_git_api_exports));
|
|
14737
14738
|
var { Scheduler: Scheduler2 } = (init_scheduler(), __toCommonJS(scheduler_exports));
|
|
@@ -15414,10 +15415,10 @@ const REMOTE_URL_PREFIXES = [
|
|
|
15414
15415
|
"github.com/neetozone/",
|
|
15415
15416
|
];
|
|
15416
15417
|
|
|
15417
|
-
const run$1 =
|
|
15418
|
+
const run$1 = util$3.promisify(exec);
|
|
15418
15419
|
|
|
15419
15420
|
const execute = async (command, debug) => {
|
|
15420
|
-
await run$1(command);
|
|
15421
|
+
const { stdout, stderr } = await run$1(command);
|
|
15421
15422
|
};
|
|
15422
15423
|
|
|
15423
15424
|
const renderErrors = (errors = [], isAutoFixFlagPresent = false) => {
|
|
@@ -15616,7 +15617,7 @@ const createOrReplaceDirectoryFiles = async ({
|
|
|
15616
15617
|
};
|
|
15617
15618
|
|
|
15618
15619
|
const runVerifiers = async ({ verifiers, autoFix, debug }) => {
|
|
15619
|
-
const { results, errors } = await getResults({ verifiers,
|
|
15620
|
+
const { results, errors } = await getResults({ verifiers, debug });
|
|
15620
15621
|
const isErrorPresent = isNotEmpty(errors);
|
|
15621
15622
|
|
|
15622
15623
|
results.map(({ name, isSuccess, status }) => {
|
|
@@ -15926,7 +15927,7 @@ const DEV_DEPENDENCIES$4 = {
|
|
|
15926
15927
|
"@eslint/eslintrc": "^3.3.1",
|
|
15927
15928
|
"@eslint/js": "^9.25.1",
|
|
15928
15929
|
"husky": "7.0.4",
|
|
15929
|
-
"globals": "
|
|
15930
|
+
"globals": "16.0.0",
|
|
15930
15931
|
"lint-staged": "12.4.1",
|
|
15931
15932
|
"postcss": "8.4.49",
|
|
15932
15933
|
"postcss-import": "^15.0.0",
|
|
@@ -15947,11 +15948,11 @@ var common = {
|
|
|
15947
15948
|
const DEPENDENCIES$3 = {
|
|
15948
15949
|
"@honeybadger-io/js": "6.10.1",
|
|
15949
15950
|
"@honeybadger-io/react": "6.1.25",
|
|
15950
|
-
"antd": "5.22.
|
|
15951
|
-
axios: "1.
|
|
15951
|
+
"antd": "5.22.1",
|
|
15952
|
+
axios: "1.13.5",
|
|
15952
15953
|
"i18next": "22.5.1",
|
|
15953
15954
|
"js-logger": "1.6.1",
|
|
15954
|
-
ramda: "0.29.
|
|
15955
|
+
ramda: "0.29.0",
|
|
15955
15956
|
react: "18.3.1",
|
|
15956
15957
|
"react-dom": "18.3.1",
|
|
15957
15958
|
"react-i18next": "12.3.1",
|
|
@@ -15989,9 +15990,9 @@ const DEV_DEPENDENCIES$2 = {
|
|
|
15989
15990
|
"@tanstack/react-query": "5.59.20",
|
|
15990
15991
|
"@tanstack/react-query-devtools": "5.59.20",
|
|
15991
15992
|
"@tippyjs/react": "4.2.6",
|
|
15992
|
-
"antd": "5.22.
|
|
15993
|
+
"antd": "5.22.1",
|
|
15993
15994
|
"avvvatars-react": "0.4.2",
|
|
15994
|
-
"axios": "1.
|
|
15995
|
+
"axios": "1.13.5",
|
|
15995
15996
|
"classnames": "2.5.1",
|
|
15996
15997
|
"crypto-browserify": "3.12.1",
|
|
15997
15998
|
"dayjs": "1.11.13",
|
|
@@ -16008,8 +16009,8 @@ const DEV_DEPENDENCIES$2 = {
|
|
|
16008
16009
|
"linkify-react": "4.3.2",
|
|
16009
16010
|
"os-browserify": "0.3.0",
|
|
16010
16011
|
"path-browserify": "1.0.1",
|
|
16011
|
-
"qs": "6.
|
|
16012
|
-
"ramda": "0.29.
|
|
16012
|
+
"qs": "6.15.0",
|
|
16013
|
+
"ramda": "0.29.0",
|
|
16013
16014
|
"react": "18.3.1",
|
|
16014
16015
|
"react-colorful": "5.6.1",
|
|
16015
16016
|
"react-dom": "18.3.1",
|
|
@@ -16047,9 +16048,9 @@ const PEER_DEPENDENCIES$2 = {
|
|
|
16047
16048
|
"@tanstack/react-query": "5.59.20",
|
|
16048
16049
|
"@tanstack/react-query-devtools": "5.59.20",
|
|
16049
16050
|
"@tippyjs/react": "4.2.6",
|
|
16050
|
-
"antd": "5.22.
|
|
16051
|
+
"antd": "5.22.1",
|
|
16051
16052
|
"avvvatars-react": "0.4.2",
|
|
16052
|
-
"axios": "1.
|
|
16053
|
+
"axios": "1.13.5",
|
|
16053
16054
|
"classnames": "2.5.1",
|
|
16054
16055
|
"crypto-browserify": "3.12.1",
|
|
16055
16056
|
"dayjs": "1.11.13",
|
|
@@ -16066,8 +16067,8 @@ const PEER_DEPENDENCIES$2 = {
|
|
|
16066
16067
|
"linkify-react": "4.3.2",
|
|
16067
16068
|
"os-browserify": "0.3.0",
|
|
16068
16069
|
"path-browserify": "^1.0.1",
|
|
16069
|
-
"qs": "6.
|
|
16070
|
-
"ramda": "0.29.
|
|
16070
|
+
"qs": "6.15.0",
|
|
16071
|
+
"ramda": "0.29.0",
|
|
16071
16072
|
"react": "18.3.1",
|
|
16072
16073
|
"react-colorful": "5.6.1",
|
|
16073
16074
|
"react-dom": "18.3.1",
|
|
@@ -16111,13 +16112,13 @@ const DEV_DEPENDENCIES$1 = {
|
|
|
16111
16112
|
"@svgr/rollup": "8.1.0",
|
|
16112
16113
|
"@tanstack/react-query": "5.59.20",
|
|
16113
16114
|
"@tanstack/react-query-devtools": "5.59.20",
|
|
16114
|
-
"antd": "5.22.
|
|
16115
|
-
axios: "1.
|
|
16115
|
+
"antd": "5.22.1",
|
|
16116
|
+
axios: "1.13.5",
|
|
16116
16117
|
classnames: "2.5.1",
|
|
16117
16118
|
formik: "2.4.6",
|
|
16118
16119
|
"i18next": "22.5.1",
|
|
16119
16120
|
"js-logger": "1.6.1",
|
|
16120
|
-
qs: "6.
|
|
16121
|
+
qs: "6.15.0",
|
|
16121
16122
|
ramda: "0.29.0",
|
|
16122
16123
|
react: "18.3.1",
|
|
16123
16124
|
"react-dom": "18.3.1",
|
|
@@ -16141,7 +16142,7 @@ const PEER_DEPENDENCIES$1 = {
|
|
|
16141
16142
|
"@honeybadger-io/react": "6.1.25",
|
|
16142
16143
|
"@tanstack/react-query": "5.59.20",
|
|
16143
16144
|
"@tanstack/react-query-devtools": "5.59.20",
|
|
16144
|
-
axios: "1.
|
|
16145
|
+
axios: "1.13.5",
|
|
16145
16146
|
classnames: "2.5.1",
|
|
16146
16147
|
formik: "2.4.6",
|
|
16147
16148
|
"i18next": "22.5.1",
|
|
@@ -16176,6 +16177,13 @@ var widget = {
|
|
|
16176
16177
|
|
|
16177
16178
|
var recommendedDependencies = { common, extension, frontend, nano, widget };
|
|
16178
16179
|
|
|
16180
|
+
/**
|
|
16181
|
+
* Create a bound version of a function with a specified `this` context
|
|
16182
|
+
*
|
|
16183
|
+
* @param {Function} fn - The function to bind
|
|
16184
|
+
* @param {*} thisArg - The value to be passed as the `this` parameter
|
|
16185
|
+
* @returns {Function} A new function that will call the original function with the specified `this` context
|
|
16186
|
+
*/
|
|
16179
16187
|
function bind$2(fn, thisArg) {
|
|
16180
16188
|
return function wrap() {
|
|
16181
16189
|
return fn.apply(thisArg, arguments);
|
|
@@ -16184,30 +16192,30 @@ function bind$2(fn, thisArg) {
|
|
|
16184
16192
|
|
|
16185
16193
|
// utils is a library of generic helper functions non-specific to axios
|
|
16186
16194
|
|
|
16187
|
-
const {toString} = Object.prototype;
|
|
16188
|
-
const {getPrototypeOf} = Object;
|
|
16189
|
-
const {iterator, toStringTag: toStringTag$1} = Symbol;
|
|
16195
|
+
const { toString } = Object.prototype;
|
|
16196
|
+
const { getPrototypeOf } = Object;
|
|
16197
|
+
const { iterator, toStringTag: toStringTag$1 } = Symbol;
|
|
16190
16198
|
|
|
16191
|
-
const kindOf = (cache => thing => {
|
|
16192
|
-
|
|
16193
|
-
|
|
16199
|
+
const kindOf = ((cache) => (thing) => {
|
|
16200
|
+
const str = toString.call(thing);
|
|
16201
|
+
return cache[str] || (cache[str] = str.slice(8, -1).toLowerCase());
|
|
16194
16202
|
})(Object.create(null));
|
|
16195
16203
|
|
|
16196
16204
|
const kindOfTest = (type) => {
|
|
16197
16205
|
type = type.toLowerCase();
|
|
16198
|
-
return (thing) => kindOf(thing) === type
|
|
16206
|
+
return (thing) => kindOf(thing) === type;
|
|
16199
16207
|
};
|
|
16200
16208
|
|
|
16201
|
-
const typeOfTest = type => thing => typeof thing === type;
|
|
16209
|
+
const typeOfTest = (type) => (thing) => typeof thing === type;
|
|
16202
16210
|
|
|
16203
16211
|
/**
|
|
16204
|
-
* Determine if a value is
|
|
16212
|
+
* Determine if a value is a non-null object
|
|
16205
16213
|
*
|
|
16206
16214
|
* @param {Object} val The value to test
|
|
16207
16215
|
*
|
|
16208
16216
|
* @returns {boolean} True if value is an Array, otherwise false
|
|
16209
16217
|
*/
|
|
16210
|
-
const {isArray} = Array;
|
|
16218
|
+
const { isArray } = Array;
|
|
16211
16219
|
|
|
16212
16220
|
/**
|
|
16213
16221
|
* Determine if a value is undefined
|
|
@@ -16216,7 +16224,7 @@ const {isArray} = Array;
|
|
|
16216
16224
|
*
|
|
16217
16225
|
* @returns {boolean} True if the value is undefined, otherwise false
|
|
16218
16226
|
*/
|
|
16219
|
-
const isUndefined = typeOfTest(
|
|
16227
|
+
const isUndefined = typeOfTest("undefined");
|
|
16220
16228
|
|
|
16221
16229
|
/**
|
|
16222
16230
|
* Determine if a value is a Buffer
|
|
@@ -16226,8 +16234,14 @@ const isUndefined = typeOfTest('undefined');
|
|
|
16226
16234
|
* @returns {boolean} True if value is a Buffer, otherwise false
|
|
16227
16235
|
*/
|
|
16228
16236
|
function isBuffer$1(val) {
|
|
16229
|
-
return
|
|
16230
|
-
|
|
16237
|
+
return (
|
|
16238
|
+
val !== null &&
|
|
16239
|
+
!isUndefined(val) &&
|
|
16240
|
+
val.constructor !== null &&
|
|
16241
|
+
!isUndefined(val.constructor) &&
|
|
16242
|
+
isFunction$2(val.constructor.isBuffer) &&
|
|
16243
|
+
val.constructor.isBuffer(val)
|
|
16244
|
+
);
|
|
16231
16245
|
}
|
|
16232
16246
|
|
|
16233
16247
|
/**
|
|
@@ -16237,8 +16251,7 @@ function isBuffer$1(val) {
|
|
|
16237
16251
|
*
|
|
16238
16252
|
* @returns {boolean} True if value is an ArrayBuffer, otherwise false
|
|
16239
16253
|
*/
|
|
16240
|
-
const isArrayBuffer = kindOfTest(
|
|
16241
|
-
|
|
16254
|
+
const isArrayBuffer = kindOfTest("ArrayBuffer");
|
|
16242
16255
|
|
|
16243
16256
|
/**
|
|
16244
16257
|
* Determine if a value is a view on an ArrayBuffer
|
|
@@ -16249,10 +16262,10 @@ const isArrayBuffer = kindOfTest('ArrayBuffer');
|
|
|
16249
16262
|
*/
|
|
16250
16263
|
function isArrayBufferView(val) {
|
|
16251
16264
|
let result;
|
|
16252
|
-
if (
|
|
16265
|
+
if (typeof ArrayBuffer !== "undefined" && ArrayBuffer.isView) {
|
|
16253
16266
|
result = ArrayBuffer.isView(val);
|
|
16254
16267
|
} else {
|
|
16255
|
-
result =
|
|
16268
|
+
result = val && val.buffer && isArrayBuffer(val.buffer);
|
|
16256
16269
|
}
|
|
16257
16270
|
return result;
|
|
16258
16271
|
}
|
|
@@ -16264,7 +16277,7 @@ function isArrayBufferView(val) {
|
|
|
16264
16277
|
*
|
|
16265
16278
|
* @returns {boolean} True if value is a String, otherwise false
|
|
16266
16279
|
*/
|
|
16267
|
-
const isString$1 = typeOfTest(
|
|
16280
|
+
const isString$1 = typeOfTest("string");
|
|
16268
16281
|
|
|
16269
16282
|
/**
|
|
16270
16283
|
* Determine if a value is a Function
|
|
@@ -16272,7 +16285,7 @@ const isString$1 = typeOfTest('string');
|
|
|
16272
16285
|
* @param {*} val The value to test
|
|
16273
16286
|
* @returns {boolean} True if value is a Function, otherwise false
|
|
16274
16287
|
*/
|
|
16275
|
-
const isFunction$2 = typeOfTest(
|
|
16288
|
+
const isFunction$2 = typeOfTest("function");
|
|
16276
16289
|
|
|
16277
16290
|
/**
|
|
16278
16291
|
* Determine if a value is a Number
|
|
@@ -16281,7 +16294,7 @@ const isFunction$2 = typeOfTest('function');
|
|
|
16281
16294
|
*
|
|
16282
16295
|
* @returns {boolean} True if value is a Number, otherwise false
|
|
16283
16296
|
*/
|
|
16284
|
-
const isNumber = typeOfTest(
|
|
16297
|
+
const isNumber = typeOfTest("number");
|
|
16285
16298
|
|
|
16286
16299
|
/**
|
|
16287
16300
|
* Determine if a value is an Object
|
|
@@ -16290,7 +16303,7 @@ const isNumber = typeOfTest('number');
|
|
|
16290
16303
|
*
|
|
16291
16304
|
* @returns {boolean} True if value is an Object, otherwise false
|
|
16292
16305
|
*/
|
|
16293
|
-
const isObject = (thing) => thing !== null && typeof thing ===
|
|
16306
|
+
const isObject = (thing) => thing !== null && typeof thing === "object";
|
|
16294
16307
|
|
|
16295
16308
|
/**
|
|
16296
16309
|
* Determine if a value is a Boolean
|
|
@@ -16298,7 +16311,7 @@ const isObject = (thing) => thing !== null && typeof thing === 'object';
|
|
|
16298
16311
|
* @param {*} thing The value to test
|
|
16299
16312
|
* @returns {boolean} True if value is a Boolean, otherwise false
|
|
16300
16313
|
*/
|
|
16301
|
-
const isBoolean = thing => thing === true || thing === false;
|
|
16314
|
+
const isBoolean = (thing) => thing === true || thing === false;
|
|
16302
16315
|
|
|
16303
16316
|
/**
|
|
16304
16317
|
* Determine if a value is a plain Object
|
|
@@ -16308,12 +16321,18 @@ const isBoolean = thing => thing === true || thing === false;
|
|
|
16308
16321
|
* @returns {boolean} True if value is a plain Object, otherwise false
|
|
16309
16322
|
*/
|
|
16310
16323
|
const isPlainObject = (val) => {
|
|
16311
|
-
if (kindOf(val) !==
|
|
16324
|
+
if (kindOf(val) !== "object") {
|
|
16312
16325
|
return false;
|
|
16313
16326
|
}
|
|
16314
16327
|
|
|
16315
16328
|
const prototype = getPrototypeOf(val);
|
|
16316
|
-
return (
|
|
16329
|
+
return (
|
|
16330
|
+
(prototype === null ||
|
|
16331
|
+
prototype === Object.prototype ||
|
|
16332
|
+
Object.getPrototypeOf(prototype) === null) &&
|
|
16333
|
+
!(toStringTag$1 in val) &&
|
|
16334
|
+
!(iterator in val)
|
|
16335
|
+
);
|
|
16317
16336
|
};
|
|
16318
16337
|
|
|
16319
16338
|
/**
|
|
@@ -16330,7 +16349,10 @@ const isEmptyObject = (val) => {
|
|
|
16330
16349
|
}
|
|
16331
16350
|
|
|
16332
16351
|
try {
|
|
16333
|
-
return
|
|
16352
|
+
return (
|
|
16353
|
+
Object.keys(val).length === 0 &&
|
|
16354
|
+
Object.getPrototypeOf(val) === Object.prototype
|
|
16355
|
+
);
|
|
16334
16356
|
} catch (e) {
|
|
16335
16357
|
// Fallback for any other objects that might cause RangeError with Object.keys()
|
|
16336
16358
|
return false;
|
|
@@ -16344,7 +16366,7 @@ const isEmptyObject = (val) => {
|
|
|
16344
16366
|
*
|
|
16345
16367
|
* @returns {boolean} True if value is a Date, otherwise false
|
|
16346
16368
|
*/
|
|
16347
|
-
const isDate = kindOfTest(
|
|
16369
|
+
const isDate = kindOfTest("Date");
|
|
16348
16370
|
|
|
16349
16371
|
/**
|
|
16350
16372
|
* Determine if a value is a File
|
|
@@ -16353,7 +16375,7 @@ const isDate = kindOfTest('Date');
|
|
|
16353
16375
|
*
|
|
16354
16376
|
* @returns {boolean} True if value is a File, otherwise false
|
|
16355
16377
|
*/
|
|
16356
|
-
const isFile = kindOfTest(
|
|
16378
|
+
const isFile = kindOfTest("File");
|
|
16357
16379
|
|
|
16358
16380
|
/**
|
|
16359
16381
|
* Determine if a value is a Blob
|
|
@@ -16362,7 +16384,7 @@ const isFile = kindOfTest('File');
|
|
|
16362
16384
|
*
|
|
16363
16385
|
* @returns {boolean} True if value is a Blob, otherwise false
|
|
16364
16386
|
*/
|
|
16365
|
-
const isBlob = kindOfTest(
|
|
16387
|
+
const isBlob = kindOfTest("Blob");
|
|
16366
16388
|
|
|
16367
16389
|
/**
|
|
16368
16390
|
* Determine if a value is a FileList
|
|
@@ -16371,7 +16393,7 @@ const isBlob = kindOfTest('Blob');
|
|
|
16371
16393
|
*
|
|
16372
16394
|
* @returns {boolean} True if value is a File, otherwise false
|
|
16373
16395
|
*/
|
|
16374
|
-
const isFileList = kindOfTest(
|
|
16396
|
+
const isFileList = kindOfTest("FileList");
|
|
16375
16397
|
|
|
16376
16398
|
/**
|
|
16377
16399
|
* Determine if a value is a Stream
|
|
@@ -16391,15 +16413,16 @@ const isStream = (val) => isObject(val) && isFunction$2(val.pipe);
|
|
|
16391
16413
|
*/
|
|
16392
16414
|
const isFormData = (thing) => {
|
|
16393
16415
|
let kind;
|
|
16394
|
-
return
|
|
16395
|
-
|
|
16396
|
-
|
|
16397
|
-
|
|
16398
|
-
|
|
16399
|
-
|
|
16400
|
-
|
|
16401
|
-
|
|
16402
|
-
|
|
16416
|
+
return (
|
|
16417
|
+
thing &&
|
|
16418
|
+
((typeof FormData === "function" && thing instanceof FormData) ||
|
|
16419
|
+
(isFunction$2(thing.append) &&
|
|
16420
|
+
((kind = kindOf(thing)) === "formdata" ||
|
|
16421
|
+
// detect form-data instance
|
|
16422
|
+
(kind === "object" &&
|
|
16423
|
+
isFunction$2(thing.toString) &&
|
|
16424
|
+
thing.toString() === "[object FormData]"))))
|
|
16425
|
+
);
|
|
16403
16426
|
};
|
|
16404
16427
|
|
|
16405
16428
|
/**
|
|
@@ -16409,9 +16432,14 @@ const isFormData = (thing) => {
|
|
|
16409
16432
|
*
|
|
16410
16433
|
* @returns {boolean} True if value is a URLSearchParams object, otherwise false
|
|
16411
16434
|
*/
|
|
16412
|
-
const isURLSearchParams = kindOfTest(
|
|
16435
|
+
const isURLSearchParams = kindOfTest("URLSearchParams");
|
|
16413
16436
|
|
|
16414
|
-
const [isReadableStream, isRequest, isResponse, isHeaders] = [
|
|
16437
|
+
const [isReadableStream, isRequest, isResponse, isHeaders] = [
|
|
16438
|
+
"ReadableStream",
|
|
16439
|
+
"Request",
|
|
16440
|
+
"Response",
|
|
16441
|
+
"Headers",
|
|
16442
|
+
].map(kindOfTest);
|
|
16415
16443
|
|
|
16416
16444
|
/**
|
|
16417
16445
|
* Trim excess whitespace off the beginning and end of a string
|
|
@@ -16420,8 +16448,8 @@ const [isReadableStream, isRequest, isResponse, isHeaders] = ['ReadableStream',
|
|
|
16420
16448
|
*
|
|
16421
16449
|
* @returns {String} The String freed of excess whitespace
|
|
16422
16450
|
*/
|
|
16423
|
-
const trim = (str) =>
|
|
16424
|
-
str.trim() : str.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,
|
|
16451
|
+
const trim = (str) =>
|
|
16452
|
+
str.trim ? str.trim() : str.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
|
|
16425
16453
|
|
|
16426
16454
|
/**
|
|
16427
16455
|
* Iterate over an Array or an Object invoking a function for each item.
|
|
@@ -16432,15 +16460,16 @@ const trim = (str) => str.trim ?
|
|
|
16432
16460
|
* If 'obj' is an Object callback will be called passing
|
|
16433
16461
|
* the value, key, and complete object for each property.
|
|
16434
16462
|
*
|
|
16435
|
-
* @param {Object|Array} obj The object to iterate
|
|
16463
|
+
* @param {Object|Array<unknown>} obj The object to iterate
|
|
16436
16464
|
* @param {Function} fn The callback to invoke for each item
|
|
16437
16465
|
*
|
|
16438
|
-
* @param {
|
|
16466
|
+
* @param {Object} [options]
|
|
16467
|
+
* @param {Boolean} [options.allOwnKeys = false]
|
|
16439
16468
|
* @returns {any}
|
|
16440
16469
|
*/
|
|
16441
|
-
function forEach(obj, fn, {allOwnKeys = false} = {}) {
|
|
16470
|
+
function forEach(obj, fn, { allOwnKeys = false } = {}) {
|
|
16442
16471
|
// Don't bother if no value provided
|
|
16443
|
-
if (obj === null || typeof obj ===
|
|
16472
|
+
if (obj === null || typeof obj === "undefined") {
|
|
16444
16473
|
return;
|
|
16445
16474
|
}
|
|
16446
16475
|
|
|
@@ -16448,7 +16477,7 @@ function forEach(obj, fn, {allOwnKeys = false} = {}) {
|
|
|
16448
16477
|
let l;
|
|
16449
16478
|
|
|
16450
16479
|
// Force an array if not already something iterable
|
|
16451
|
-
if (typeof obj !==
|
|
16480
|
+
if (typeof obj !== "object") {
|
|
16452
16481
|
/*eslint no-param-reassign:0*/
|
|
16453
16482
|
obj = [obj];
|
|
16454
16483
|
}
|
|
@@ -16465,7 +16494,9 @@ function forEach(obj, fn, {allOwnKeys = false} = {}) {
|
|
|
16465
16494
|
}
|
|
16466
16495
|
|
|
16467
16496
|
// Iterate over object keys
|
|
16468
|
-
const keys = allOwnKeys
|
|
16497
|
+
const keys = allOwnKeys
|
|
16498
|
+
? Object.getOwnPropertyNames(obj)
|
|
16499
|
+
: Object.keys(obj);
|
|
16469
16500
|
const len = keys.length;
|
|
16470
16501
|
let key;
|
|
16471
16502
|
|
|
@@ -16477,7 +16508,7 @@ function forEach(obj, fn, {allOwnKeys = false} = {}) {
|
|
|
16477
16508
|
}
|
|
16478
16509
|
|
|
16479
16510
|
function findKey(obj, key) {
|
|
16480
|
-
if (isBuffer$1(obj)){
|
|
16511
|
+
if (isBuffer$1(obj)) {
|
|
16481
16512
|
return null;
|
|
16482
16513
|
}
|
|
16483
16514
|
|
|
@@ -16497,10 +16528,15 @@ function findKey(obj, key) {
|
|
|
16497
16528
|
const _global = (() => {
|
|
16498
16529
|
/*eslint no-undef:0*/
|
|
16499
16530
|
if (typeof globalThis !== "undefined") return globalThis;
|
|
16500
|
-
return typeof self !== "undefined"
|
|
16531
|
+
return typeof self !== "undefined"
|
|
16532
|
+
? self
|
|
16533
|
+
: typeof window !== "undefined"
|
|
16534
|
+
? window
|
|
16535
|
+
: global;
|
|
16501
16536
|
})();
|
|
16502
16537
|
|
|
16503
|
-
const isContextDefined = (context) =>
|
|
16538
|
+
const isContextDefined = (context) =>
|
|
16539
|
+
!isUndefined(context) && context !== _global;
|
|
16504
16540
|
|
|
16505
16541
|
/**
|
|
16506
16542
|
* Accepts varargs expecting each argument to be an object, then
|
|
@@ -16512,7 +16548,7 @@ const isContextDefined = (context) => !isUndefined(context) && context !== _glob
|
|
|
16512
16548
|
* Example:
|
|
16513
16549
|
*
|
|
16514
16550
|
* ```js
|
|
16515
|
-
*
|
|
16551
|
+
* const result = merge({foo: 123}, {foo: 456});
|
|
16516
16552
|
* console.log(result.foo); // outputs 456
|
|
16517
16553
|
* ```
|
|
16518
16554
|
*
|
|
@@ -16521,20 +16557,23 @@ const isContextDefined = (context) => !isUndefined(context) && context !== _glob
|
|
|
16521
16557
|
* @returns {Object} Result of all merge properties
|
|
16522
16558
|
*/
|
|
16523
16559
|
function merge(/* obj1, obj2, obj3, ... */) {
|
|
16524
|
-
const {caseless, skipUndefined} = isContextDefined(this) && this || {};
|
|
16560
|
+
const { caseless, skipUndefined } = (isContextDefined(this) && this) || {};
|
|
16525
16561
|
const result = {};
|
|
16526
16562
|
const assignValue = (val, key) => {
|
|
16527
|
-
|
|
16563
|
+
// Skip dangerous property names to prevent prototype pollution
|
|
16564
|
+
if (key === "__proto__" || key === "constructor" || key === "prototype") {
|
|
16565
|
+
return;
|
|
16566
|
+
}
|
|
16567
|
+
|
|
16568
|
+
const targetKey = (caseless && findKey(result, key)) || key;
|
|
16528
16569
|
if (isPlainObject(result[targetKey]) && isPlainObject(val)) {
|
|
16529
16570
|
result[targetKey] = merge(result[targetKey], val);
|
|
16530
16571
|
} else if (isPlainObject(val)) {
|
|
16531
16572
|
result[targetKey] = merge({}, val);
|
|
16532
16573
|
} else if (isArray(val)) {
|
|
16533
16574
|
result[targetKey] = val.slice();
|
|
16534
|
-
} else {
|
|
16535
|
-
|
|
16536
|
-
result[targetKey] = val;
|
|
16537
|
-
}
|
|
16575
|
+
} else if (!skipUndefined || !isUndefined(val)) {
|
|
16576
|
+
result[targetKey] = val;
|
|
16538
16577
|
}
|
|
16539
16578
|
};
|
|
16540
16579
|
|
|
@@ -16551,17 +16590,32 @@ function merge(/* obj1, obj2, obj3, ... */) {
|
|
|
16551
16590
|
* @param {Object} b The object to copy properties from
|
|
16552
16591
|
* @param {Object} thisArg The object to bind function to
|
|
16553
16592
|
*
|
|
16554
|
-
* @param {
|
|
16593
|
+
* @param {Object} [options]
|
|
16594
|
+
* @param {Boolean} [options.allOwnKeys]
|
|
16555
16595
|
* @returns {Object} The resulting value of object a
|
|
16556
16596
|
*/
|
|
16557
|
-
const extend = (a, b, thisArg, {allOwnKeys}= {}) => {
|
|
16558
|
-
forEach(
|
|
16559
|
-
|
|
16560
|
-
|
|
16561
|
-
|
|
16562
|
-
|
|
16563
|
-
|
|
16564
|
-
|
|
16597
|
+
const extend = (a, b, thisArg, { allOwnKeys } = {}) => {
|
|
16598
|
+
forEach(
|
|
16599
|
+
b,
|
|
16600
|
+
(val, key) => {
|
|
16601
|
+
if (thisArg && isFunction$2(val)) {
|
|
16602
|
+
Object.defineProperty(a, key, {
|
|
16603
|
+
value: bind$2(val, thisArg),
|
|
16604
|
+
writable: true,
|
|
16605
|
+
enumerable: true,
|
|
16606
|
+
configurable: true,
|
|
16607
|
+
});
|
|
16608
|
+
} else {
|
|
16609
|
+
Object.defineProperty(a, key, {
|
|
16610
|
+
value: val,
|
|
16611
|
+
writable: true,
|
|
16612
|
+
enumerable: true,
|
|
16613
|
+
configurable: true,
|
|
16614
|
+
});
|
|
16615
|
+
}
|
|
16616
|
+
},
|
|
16617
|
+
{ allOwnKeys },
|
|
16618
|
+
);
|
|
16565
16619
|
return a;
|
|
16566
16620
|
};
|
|
16567
16621
|
|
|
@@ -16573,7 +16627,7 @@ const extend = (a, b, thisArg, {allOwnKeys}= {}) => {
|
|
|
16573
16627
|
* @returns {string} content value without BOM
|
|
16574
16628
|
*/
|
|
16575
16629
|
const stripBOM = (content) => {
|
|
16576
|
-
if (content.charCodeAt(0) ===
|
|
16630
|
+
if (content.charCodeAt(0) === 0xfeff) {
|
|
16577
16631
|
content = content.slice(1);
|
|
16578
16632
|
}
|
|
16579
16633
|
return content;
|
|
@@ -16589,10 +16643,18 @@ const stripBOM = (content) => {
|
|
|
16589
16643
|
* @returns {void}
|
|
16590
16644
|
*/
|
|
16591
16645
|
const inherits = (constructor, superConstructor, props, descriptors) => {
|
|
16592
|
-
constructor.prototype = Object.create(
|
|
16593
|
-
|
|
16594
|
-
|
|
16595
|
-
|
|
16646
|
+
constructor.prototype = Object.create(
|
|
16647
|
+
superConstructor.prototype,
|
|
16648
|
+
descriptors,
|
|
16649
|
+
);
|
|
16650
|
+
Object.defineProperty(constructor.prototype, "constructor", {
|
|
16651
|
+
value: constructor,
|
|
16652
|
+
writable: true,
|
|
16653
|
+
enumerable: false,
|
|
16654
|
+
configurable: true,
|
|
16655
|
+
});
|
|
16656
|
+
Object.defineProperty(constructor, "super", {
|
|
16657
|
+
value: superConstructor.prototype,
|
|
16596
16658
|
});
|
|
16597
16659
|
props && Object.assign(constructor.prototype, props);
|
|
16598
16660
|
};
|
|
@@ -16621,13 +16683,20 @@ const toFlatObject = (sourceObj, destObj, filter, propFilter) => {
|
|
|
16621
16683
|
i = props.length;
|
|
16622
16684
|
while (i-- > 0) {
|
|
16623
16685
|
prop = props[i];
|
|
16624
|
-
if (
|
|
16686
|
+
if (
|
|
16687
|
+
(!propFilter || propFilter(prop, sourceObj, destObj)) &&
|
|
16688
|
+
!merged[prop]
|
|
16689
|
+
) {
|
|
16625
16690
|
destObj[prop] = sourceObj[prop];
|
|
16626
16691
|
merged[prop] = true;
|
|
16627
16692
|
}
|
|
16628
16693
|
}
|
|
16629
16694
|
sourceObj = filter !== false && getPrototypeOf(sourceObj);
|
|
16630
|
-
} while (
|
|
16695
|
+
} while (
|
|
16696
|
+
sourceObj &&
|
|
16697
|
+
(!filter || filter(sourceObj, destObj)) &&
|
|
16698
|
+
sourceObj !== Object.prototype
|
|
16699
|
+
);
|
|
16631
16700
|
|
|
16632
16701
|
return destObj;
|
|
16633
16702
|
};
|
|
@@ -16651,7 +16720,6 @@ const endsWith = (str, searchString, position) => {
|
|
|
16651
16720
|
return lastIndex !== -1 && lastIndex === position;
|
|
16652
16721
|
};
|
|
16653
16722
|
|
|
16654
|
-
|
|
16655
16723
|
/**
|
|
16656
16724
|
* Returns new array from array like object or null if failed
|
|
16657
16725
|
*
|
|
@@ -16680,12 +16748,12 @@ const toArray = (thing) => {
|
|
|
16680
16748
|
* @returns {Array}
|
|
16681
16749
|
*/
|
|
16682
16750
|
// eslint-disable-next-line func-names
|
|
16683
|
-
const isTypedArray = (TypedArray => {
|
|
16751
|
+
const isTypedArray = ((TypedArray) => {
|
|
16684
16752
|
// eslint-disable-next-line func-names
|
|
16685
|
-
return thing => {
|
|
16753
|
+
return (thing) => {
|
|
16686
16754
|
return TypedArray && thing instanceof TypedArray;
|
|
16687
16755
|
};
|
|
16688
|
-
})(typeof Uint8Array !==
|
|
16756
|
+
})(typeof Uint8Array !== "undefined" && getPrototypeOf(Uint8Array));
|
|
16689
16757
|
|
|
16690
16758
|
/**
|
|
16691
16759
|
* For each entry in the object, call the function with the key and value.
|
|
@@ -16728,18 +16796,22 @@ const matchAll = (regExp, str) => {
|
|
|
16728
16796
|
};
|
|
16729
16797
|
|
|
16730
16798
|
/* Checking if the kindOfTest function returns true when passed an HTMLFormElement. */
|
|
16731
|
-
const isHTMLForm = kindOfTest(
|
|
16799
|
+
const isHTMLForm = kindOfTest("HTMLFormElement");
|
|
16732
16800
|
|
|
16733
|
-
const toCamelCase = str => {
|
|
16734
|
-
return str
|
|
16735
|
-
|
|
16801
|
+
const toCamelCase = (str) => {
|
|
16802
|
+
return str
|
|
16803
|
+
.toLowerCase()
|
|
16804
|
+
.replace(/[-_\s]([a-z\d])(\w*)/g, function replacer(m, p1, p2) {
|
|
16736
16805
|
return p1.toUpperCase() + p2;
|
|
16737
|
-
}
|
|
16738
|
-
);
|
|
16806
|
+
});
|
|
16739
16807
|
};
|
|
16740
16808
|
|
|
16741
16809
|
/* Creating a function that will check if an object has a property. */
|
|
16742
|
-
const hasOwnProperty = (
|
|
16810
|
+
const hasOwnProperty = (
|
|
16811
|
+
({ hasOwnProperty }) =>
|
|
16812
|
+
(obj, prop) =>
|
|
16813
|
+
hasOwnProperty.call(obj, prop)
|
|
16814
|
+
)(Object.prototype);
|
|
16743
16815
|
|
|
16744
16816
|
/**
|
|
16745
16817
|
* Determine if a value is a RegExp object
|
|
@@ -16748,7 +16820,7 @@ const hasOwnProperty = (({hasOwnProperty}) => (obj, prop) => hasOwnProperty.call
|
|
|
16748
16820
|
*
|
|
16749
16821
|
* @returns {boolean} True if value is a RegExp object, otherwise false
|
|
16750
16822
|
*/
|
|
16751
|
-
const isRegExp = kindOfTest(
|
|
16823
|
+
const isRegExp = kindOfTest("RegExp");
|
|
16752
16824
|
|
|
16753
16825
|
const reduceDescriptors = (obj, reducer) => {
|
|
16754
16826
|
const descriptors = Object.getOwnPropertyDescriptors(obj);
|
|
@@ -16772,7 +16844,10 @@ const reduceDescriptors = (obj, reducer) => {
|
|
|
16772
16844
|
const freezeMethods = (obj) => {
|
|
16773
16845
|
reduceDescriptors(obj, (descriptor, name) => {
|
|
16774
16846
|
// skip restricted props in strict mode
|
|
16775
|
-
if (
|
|
16847
|
+
if (
|
|
16848
|
+
isFunction$2(obj) &&
|
|
16849
|
+
["arguments", "caller", "callee"].indexOf(name) !== -1
|
|
16850
|
+
) {
|
|
16776
16851
|
return false;
|
|
16777
16852
|
}
|
|
16778
16853
|
|
|
@@ -16782,14 +16857,14 @@ const freezeMethods = (obj) => {
|
|
|
16782
16857
|
|
|
16783
16858
|
descriptor.enumerable = false;
|
|
16784
16859
|
|
|
16785
|
-
if (
|
|
16860
|
+
if ("writable" in descriptor) {
|
|
16786
16861
|
descriptor.writable = false;
|
|
16787
16862
|
return;
|
|
16788
16863
|
}
|
|
16789
16864
|
|
|
16790
16865
|
if (!descriptor.set) {
|
|
16791
16866
|
descriptor.set = () => {
|
|
16792
|
-
throw Error(
|
|
16867
|
+
throw Error("Can not rewrite read-only method '" + name + "'");
|
|
16793
16868
|
};
|
|
16794
16869
|
}
|
|
16795
16870
|
});
|
|
@@ -16799,12 +16874,14 @@ const toObjectSet = (arrayOrString, delimiter) => {
|
|
|
16799
16874
|
const obj = {};
|
|
16800
16875
|
|
|
16801
16876
|
const define = (arr) => {
|
|
16802
|
-
arr.forEach(value => {
|
|
16877
|
+
arr.forEach((value) => {
|
|
16803
16878
|
obj[value] = true;
|
|
16804
16879
|
});
|
|
16805
16880
|
};
|
|
16806
16881
|
|
|
16807
|
-
isArray(arrayOrString)
|
|
16882
|
+
isArray(arrayOrString)
|
|
16883
|
+
? define(arrayOrString)
|
|
16884
|
+
: define(String(arrayOrString).split(delimiter));
|
|
16808
16885
|
|
|
16809
16886
|
return obj;
|
|
16810
16887
|
};
|
|
@@ -16812,11 +16889,11 @@ const toObjectSet = (arrayOrString, delimiter) => {
|
|
|
16812
16889
|
const noop$1 = () => {};
|
|
16813
16890
|
|
|
16814
16891
|
const toFiniteNumber = (value, defaultValue) => {
|
|
16815
|
-
return value != null && Number.isFinite(value = +value)
|
|
16892
|
+
return value != null && Number.isFinite((value = +value))
|
|
16893
|
+
? value
|
|
16894
|
+
: defaultValue;
|
|
16816
16895
|
};
|
|
16817
16896
|
|
|
16818
|
-
|
|
16819
|
-
|
|
16820
16897
|
/**
|
|
16821
16898
|
* If the thing is a FormData object, return true, otherwise return false.
|
|
16822
16899
|
*
|
|
@@ -16825,14 +16902,18 @@ const toFiniteNumber = (value, defaultValue) => {
|
|
|
16825
16902
|
* @returns {boolean}
|
|
16826
16903
|
*/
|
|
16827
16904
|
function isSpecCompliantForm(thing) {
|
|
16828
|
-
return !!(
|
|
16905
|
+
return !!(
|
|
16906
|
+
thing &&
|
|
16907
|
+
isFunction$2(thing.append) &&
|
|
16908
|
+
thing[toStringTag$1] === "FormData" &&
|
|
16909
|
+
thing[iterator]
|
|
16910
|
+
);
|
|
16829
16911
|
}
|
|
16830
16912
|
|
|
16831
16913
|
const toJSONObject = (obj) => {
|
|
16832
16914
|
const stack = new Array(10);
|
|
16833
16915
|
|
|
16834
16916
|
const visit = (source, i) => {
|
|
16835
|
-
|
|
16836
16917
|
if (isObject(source)) {
|
|
16837
16918
|
if (stack.indexOf(source) >= 0) {
|
|
16838
16919
|
return;
|
|
@@ -16843,7 +16924,7 @@ const toJSONObject = (obj) => {
|
|
|
16843
16924
|
return source;
|
|
16844
16925
|
}
|
|
16845
16926
|
|
|
16846
|
-
if(!(
|
|
16927
|
+
if (!("toJSON" in source)) {
|
|
16847
16928
|
stack[i] = source;
|
|
16848
16929
|
const target = isArray(source) ? [] : {};
|
|
16849
16930
|
|
|
@@ -16864,10 +16945,13 @@ const toJSONObject = (obj) => {
|
|
|
16864
16945
|
return visit(obj, 0);
|
|
16865
16946
|
};
|
|
16866
16947
|
|
|
16867
|
-
const isAsyncFn = kindOfTest(
|
|
16948
|
+
const isAsyncFn = kindOfTest("AsyncFunction");
|
|
16868
16949
|
|
|
16869
16950
|
const isThenable = (thing) =>
|
|
16870
|
-
thing &&
|
|
16951
|
+
thing &&
|
|
16952
|
+
(isObject(thing) || isFunction$2(thing)) &&
|
|
16953
|
+
isFunction$2(thing.then) &&
|
|
16954
|
+
isFunction$2(thing.catch);
|
|
16871
16955
|
|
|
16872
16956
|
// original code
|
|
16873
16957
|
// https://github.com/DigitalBrainJS/AxiosPromise/blob/16deab13710ec09779922131f3fa5954320f83ab/lib/utils.js#L11-L34
|
|
@@ -16877,32 +16961,35 @@ const _setImmediate = ((setImmediateSupported, postMessageSupported) => {
|
|
|
16877
16961
|
return setImmediate;
|
|
16878
16962
|
}
|
|
16879
16963
|
|
|
16880
|
-
return postMessageSupported
|
|
16881
|
-
|
|
16882
|
-
|
|
16883
|
-
|
|
16884
|
-
|
|
16885
|
-
|
|
16964
|
+
return postMessageSupported
|
|
16965
|
+
? ((token, callbacks) => {
|
|
16966
|
+
_global.addEventListener(
|
|
16967
|
+
"message",
|
|
16968
|
+
({ source, data }) => {
|
|
16969
|
+
if (source === _global && data === token) {
|
|
16970
|
+
callbacks.length && callbacks.shift()();
|
|
16971
|
+
}
|
|
16972
|
+
},
|
|
16973
|
+
false,
|
|
16974
|
+
);
|
|
16886
16975
|
|
|
16887
|
-
|
|
16888
|
-
|
|
16889
|
-
|
|
16890
|
-
|
|
16891
|
-
|
|
16892
|
-
|
|
16893
|
-
|
|
16894
|
-
isFunction$2(_global.postMessage)
|
|
16895
|
-
);
|
|
16976
|
+
return (cb) => {
|
|
16977
|
+
callbacks.push(cb);
|
|
16978
|
+
_global.postMessage(token, "*");
|
|
16979
|
+
};
|
|
16980
|
+
})(`axios@${Math.random()}`, [])
|
|
16981
|
+
: (cb) => setTimeout(cb);
|
|
16982
|
+
})(typeof setImmediate === "function", isFunction$2(_global.postMessage));
|
|
16896
16983
|
|
|
16897
|
-
const asap =
|
|
16898
|
-
|
|
16984
|
+
const asap =
|
|
16985
|
+
typeof queueMicrotask !== "undefined"
|
|
16986
|
+
? queueMicrotask.bind(_global)
|
|
16987
|
+
: (typeof process !== "undefined" && process.nextTick) || _setImmediate;
|
|
16899
16988
|
|
|
16900
16989
|
// *********************
|
|
16901
16990
|
|
|
16902
|
-
|
|
16903
16991
|
const isIterable = (thing) => thing != null && isFunction$2(thing[iterator]);
|
|
16904
16992
|
|
|
16905
|
-
|
|
16906
16993
|
var utils$1 = {
|
|
16907
16994
|
isArray,
|
|
16908
16995
|
isArrayBuffer,
|
|
@@ -16960,116 +17047,79 @@ var utils$1 = {
|
|
|
16960
17047
|
isThenable,
|
|
16961
17048
|
setImmediate: _setImmediate,
|
|
16962
17049
|
asap,
|
|
16963
|
-
isIterable
|
|
17050
|
+
isIterable,
|
|
16964
17051
|
};
|
|
16965
17052
|
|
|
16966
|
-
|
|
16967
|
-
|
|
16968
|
-
|
|
16969
|
-
|
|
16970
|
-
|
|
16971
|
-
|
|
16972
|
-
|
|
16973
|
-
|
|
16974
|
-
*
|
|
16975
|
-
* @returns {Error} The created error.
|
|
16976
|
-
*/
|
|
16977
|
-
function AxiosError(message, code, config, request, response) {
|
|
16978
|
-
Error.call(this);
|
|
16979
|
-
|
|
16980
|
-
if (Error.captureStackTrace) {
|
|
16981
|
-
Error.captureStackTrace(this, this.constructor);
|
|
16982
|
-
} else {
|
|
16983
|
-
this.stack = (new Error()).stack;
|
|
16984
|
-
}
|
|
16985
|
-
|
|
16986
|
-
this.message = message;
|
|
16987
|
-
this.name = 'AxiosError';
|
|
16988
|
-
code && (this.code = code);
|
|
16989
|
-
config && (this.config = config);
|
|
16990
|
-
request && (this.request = request);
|
|
16991
|
-
if (response) {
|
|
16992
|
-
this.response = response;
|
|
16993
|
-
this.status = response.status ? response.status : null;
|
|
16994
|
-
}
|
|
16995
|
-
}
|
|
16996
|
-
|
|
16997
|
-
utils$1.inherits(AxiosError, Error, {
|
|
16998
|
-
toJSON: function toJSON() {
|
|
16999
|
-
return {
|
|
17000
|
-
// Standard
|
|
17001
|
-
message: this.message,
|
|
17002
|
-
name: this.name,
|
|
17003
|
-
// Microsoft
|
|
17004
|
-
description: this.description,
|
|
17005
|
-
number: this.number,
|
|
17006
|
-
// Mozilla
|
|
17007
|
-
fileName: this.fileName,
|
|
17008
|
-
lineNumber: this.lineNumber,
|
|
17009
|
-
columnNumber: this.columnNumber,
|
|
17010
|
-
stack: this.stack,
|
|
17011
|
-
// Axios
|
|
17012
|
-
config: utils$1.toJSONObject(this.config),
|
|
17013
|
-
code: this.code,
|
|
17014
|
-
status: this.status
|
|
17015
|
-
};
|
|
17016
|
-
}
|
|
17017
|
-
});
|
|
17018
|
-
|
|
17019
|
-
const prototype$1 = AxiosError.prototype;
|
|
17020
|
-
const descriptors = {};
|
|
17021
|
-
|
|
17022
|
-
[
|
|
17023
|
-
'ERR_BAD_OPTION_VALUE',
|
|
17024
|
-
'ERR_BAD_OPTION',
|
|
17025
|
-
'ECONNABORTED',
|
|
17026
|
-
'ETIMEDOUT',
|
|
17027
|
-
'ERR_NETWORK',
|
|
17028
|
-
'ERR_FR_TOO_MANY_REDIRECTS',
|
|
17029
|
-
'ERR_DEPRECATED',
|
|
17030
|
-
'ERR_BAD_RESPONSE',
|
|
17031
|
-
'ERR_BAD_REQUEST',
|
|
17032
|
-
'ERR_CANCELED',
|
|
17033
|
-
'ERR_NOT_SUPPORT',
|
|
17034
|
-
'ERR_INVALID_URL'
|
|
17035
|
-
// eslint-disable-next-line func-names
|
|
17036
|
-
].forEach(code => {
|
|
17037
|
-
descriptors[code] = {value: code};
|
|
17038
|
-
});
|
|
17039
|
-
|
|
17040
|
-
Object.defineProperties(AxiosError, descriptors);
|
|
17041
|
-
Object.defineProperty(prototype$1, 'isAxiosError', {value: true});
|
|
17042
|
-
|
|
17043
|
-
// eslint-disable-next-line func-names
|
|
17044
|
-
AxiosError.from = (error, code, config, request, response, customProps) => {
|
|
17045
|
-
const axiosError = Object.create(prototype$1);
|
|
17046
|
-
|
|
17047
|
-
utils$1.toFlatObject(error, axiosError, function filter(obj) {
|
|
17048
|
-
return obj !== Error.prototype;
|
|
17049
|
-
}, prop => {
|
|
17050
|
-
return prop !== 'isAxiosError';
|
|
17051
|
-
});
|
|
17052
|
-
|
|
17053
|
-
const msg = error && error.message ? error.message : 'Error';
|
|
17054
|
-
|
|
17055
|
-
// Prefer explicit code; otherwise copy the low-level error's code (e.g. ECONNREFUSED)
|
|
17056
|
-
const errCode = code == null && error ? error.code : code;
|
|
17057
|
-
AxiosError.call(axiosError, msg, errCode, config, request, response);
|
|
17058
|
-
|
|
17059
|
-
// Chain the original error on the standard field; non-enumerable to avoid JSON noise
|
|
17060
|
-
if (error && axiosError.cause == null) {
|
|
17061
|
-
Object.defineProperty(axiosError, 'cause', { value: error, configurable: true });
|
|
17062
|
-
}
|
|
17063
|
-
|
|
17064
|
-
axiosError.name = (error && error.name) || 'Error';
|
|
17053
|
+
let AxiosError$1 = class AxiosError extends Error {
|
|
17054
|
+
static from(error, code, config, request, response, customProps) {
|
|
17055
|
+
const axiosError = new AxiosError(error.message, code || error.code, config, request, response);
|
|
17056
|
+
axiosError.cause = error;
|
|
17057
|
+
axiosError.name = error.name;
|
|
17058
|
+
customProps && Object.assign(axiosError, customProps);
|
|
17059
|
+
return axiosError;
|
|
17060
|
+
}
|
|
17065
17061
|
|
|
17066
|
-
|
|
17062
|
+
/**
|
|
17063
|
+
* Create an Error with the specified message, config, error code, request and response.
|
|
17064
|
+
*
|
|
17065
|
+
* @param {string} message The error message.
|
|
17066
|
+
* @param {string} [code] The error code (for example, 'ECONNABORTED').
|
|
17067
|
+
* @param {Object} [config] The config.
|
|
17068
|
+
* @param {Object} [request] The request.
|
|
17069
|
+
* @param {Object} [response] The response.
|
|
17070
|
+
*
|
|
17071
|
+
* @returns {Error} The created error.
|
|
17072
|
+
*/
|
|
17073
|
+
constructor(message, code, config, request, response) {
|
|
17074
|
+
super(message);
|
|
17075
|
+
this.name = 'AxiosError';
|
|
17076
|
+
this.isAxiosError = true;
|
|
17077
|
+
code && (this.code = code);
|
|
17078
|
+
config && (this.config = config);
|
|
17079
|
+
request && (this.request = request);
|
|
17080
|
+
if (response) {
|
|
17081
|
+
this.response = response;
|
|
17082
|
+
this.status = response.status;
|
|
17083
|
+
}
|
|
17084
|
+
}
|
|
17067
17085
|
|
|
17068
|
-
|
|
17086
|
+
toJSON() {
|
|
17087
|
+
return {
|
|
17088
|
+
// Standard
|
|
17089
|
+
message: this.message,
|
|
17090
|
+
name: this.name,
|
|
17091
|
+
// Microsoft
|
|
17092
|
+
description: this.description,
|
|
17093
|
+
number: this.number,
|
|
17094
|
+
// Mozilla
|
|
17095
|
+
fileName: this.fileName,
|
|
17096
|
+
lineNumber: this.lineNumber,
|
|
17097
|
+
columnNumber: this.columnNumber,
|
|
17098
|
+
stack: this.stack,
|
|
17099
|
+
// Axios
|
|
17100
|
+
config: utils$1.toJSONObject(this.config),
|
|
17101
|
+
code: this.code,
|
|
17102
|
+
status: this.status,
|
|
17103
|
+
};
|
|
17104
|
+
}
|
|
17069
17105
|
};
|
|
17070
17106
|
|
|
17107
|
+
// This can be changed to static properties as soon as the parser options in .eslint.cjs are updated.
|
|
17108
|
+
AxiosError$1.ERR_BAD_OPTION_VALUE = 'ERR_BAD_OPTION_VALUE';
|
|
17109
|
+
AxiosError$1.ERR_BAD_OPTION = 'ERR_BAD_OPTION';
|
|
17110
|
+
AxiosError$1.ECONNABORTED = 'ECONNABORTED';
|
|
17111
|
+
AxiosError$1.ETIMEDOUT = 'ETIMEDOUT';
|
|
17112
|
+
AxiosError$1.ERR_NETWORK = 'ERR_NETWORK';
|
|
17113
|
+
AxiosError$1.ERR_FR_TOO_MANY_REDIRECTS = 'ERR_FR_TOO_MANY_REDIRECTS';
|
|
17114
|
+
AxiosError$1.ERR_DEPRECATED = 'ERR_DEPRECATED';
|
|
17115
|
+
AxiosError$1.ERR_BAD_RESPONSE = 'ERR_BAD_RESPONSE';
|
|
17116
|
+
AxiosError$1.ERR_BAD_REQUEST = 'ERR_BAD_REQUEST';
|
|
17117
|
+
AxiosError$1.ERR_CANCELED = 'ERR_CANCELED';
|
|
17118
|
+
AxiosError$1.ERR_NOT_SUPPORT = 'ERR_NOT_SUPPORT';
|
|
17119
|
+
AxiosError$1.ERR_INVALID_URL = 'ERR_INVALID_URL';
|
|
17120
|
+
|
|
17071
17121
|
var Stream$2 = stream.Stream;
|
|
17072
|
-
var util$2 =
|
|
17122
|
+
var util$2 = util$3;
|
|
17073
17123
|
|
|
17074
17124
|
var delayed_stream = DelayedStream$1;
|
|
17075
17125
|
function DelayedStream$1() {
|
|
@@ -17176,7 +17226,7 @@ DelayedStream$1.prototype._checkIfMaxDataSizeExceeded = function() {
|
|
|
17176
17226
|
this.emit('error', new Error(message));
|
|
17177
17227
|
};
|
|
17178
17228
|
|
|
17179
|
-
var util$1 =
|
|
17229
|
+
var util$1 = util$3;
|
|
17180
17230
|
var Stream$1 = stream.Stream;
|
|
17181
17231
|
var DelayedStream = delayed_stream;
|
|
17182
17232
|
|
|
@@ -28110,7 +28160,7 @@ var mimeDb = require$$0;
|
|
|
28110
28160
|
* MIT Licensed
|
|
28111
28161
|
*/
|
|
28112
28162
|
|
|
28113
|
-
(function (exports) {
|
|
28163
|
+
(function (exports$1) {
|
|
28114
28164
|
|
|
28115
28165
|
/**
|
|
28116
28166
|
* Module dependencies.
|
|
@@ -28133,16 +28183,16 @@ var mimeDb = require$$0;
|
|
|
28133
28183
|
* @public
|
|
28134
28184
|
*/
|
|
28135
28185
|
|
|
28136
|
-
exports.charset = charset;
|
|
28137
|
-
exports.charsets = { lookup: charset };
|
|
28138
|
-
exports.contentType = contentType;
|
|
28139
|
-
exports.extension = extension;
|
|
28140
|
-
exports.extensions = Object.create(null);
|
|
28141
|
-
exports.lookup = lookup;
|
|
28142
|
-
exports.types = Object.create(null);
|
|
28186
|
+
exports$1.charset = charset;
|
|
28187
|
+
exports$1.charsets = { lookup: charset };
|
|
28188
|
+
exports$1.contentType = contentType;
|
|
28189
|
+
exports$1.extension = extension;
|
|
28190
|
+
exports$1.extensions = Object.create(null);
|
|
28191
|
+
exports$1.lookup = lookup;
|
|
28192
|
+
exports$1.types = Object.create(null);
|
|
28143
28193
|
|
|
28144
28194
|
// Populate the extensions/types maps
|
|
28145
|
-
populateMaps(exports.extensions, exports.types);
|
|
28195
|
+
populateMaps(exports$1.extensions, exports$1.types);
|
|
28146
28196
|
|
|
28147
28197
|
/**
|
|
28148
28198
|
* Get the default charset for a MIME type.
|
|
@@ -28186,7 +28236,7 @@ var mimeDb = require$$0;
|
|
|
28186
28236
|
}
|
|
28187
28237
|
|
|
28188
28238
|
var mime = str.indexOf('/') === -1
|
|
28189
|
-
? exports.lookup(str)
|
|
28239
|
+
? exports$1.lookup(str)
|
|
28190
28240
|
: str;
|
|
28191
28241
|
|
|
28192
28242
|
if (!mime) {
|
|
@@ -28195,7 +28245,7 @@ var mimeDb = require$$0;
|
|
|
28195
28245
|
|
|
28196
28246
|
// TODO: use content-type or other module
|
|
28197
28247
|
if (mime.indexOf('charset') === -1) {
|
|
28198
|
-
var charset = exports.charset(mime);
|
|
28248
|
+
var charset = exports$1.charset(mime);
|
|
28199
28249
|
if (charset) mime += '; charset=' + charset.toLowerCase();
|
|
28200
28250
|
}
|
|
28201
28251
|
|
|
@@ -28218,7 +28268,7 @@ var mimeDb = require$$0;
|
|
|
28218
28268
|
var match = EXTRACT_TYPE_REGEXP.exec(type);
|
|
28219
28269
|
|
|
28220
28270
|
// get extensions
|
|
28221
|
-
var exts = match && exports.extensions[match[1].toLowerCase()];
|
|
28271
|
+
var exts = match && exports$1.extensions[match[1].toLowerCase()];
|
|
28222
28272
|
|
|
28223
28273
|
if (!exts || !exts.length) {
|
|
28224
28274
|
return false
|
|
@@ -28248,7 +28298,7 @@ var mimeDb = require$$0;
|
|
|
28248
28298
|
return false
|
|
28249
28299
|
}
|
|
28250
28300
|
|
|
28251
|
-
return exports.types[extension] || false
|
|
28301
|
+
return exports$1.types[extension] || false
|
|
28252
28302
|
}
|
|
28253
28303
|
|
|
28254
28304
|
/**
|
|
@@ -28741,7 +28791,7 @@ var sign$1 = function sign(number) {
|
|
|
28741
28791
|
if ($isNaN(number) || number === 0) {
|
|
28742
28792
|
return number;
|
|
28743
28793
|
}
|
|
28744
|
-
return number < 0 ? -1 :
|
|
28794
|
+
return number < 0 ? -1 : 1;
|
|
28745
28795
|
};
|
|
28746
28796
|
|
|
28747
28797
|
/** @type {import('./gOPD')} */
|
|
@@ -29556,7 +29606,7 @@ var populate$1 = function (dst, src) {
|
|
|
29556
29606
|
};
|
|
29557
29607
|
|
|
29558
29608
|
var CombinedStream = combined_stream;
|
|
29559
|
-
var util =
|
|
29609
|
+
var util = util$3;
|
|
29560
29610
|
var path = path$2;
|
|
29561
29611
|
var http$1 = require$$3$1;
|
|
29562
29612
|
var https$1 = require$$4$1;
|
|
@@ -30019,7 +30069,7 @@ FormData$1.prototype.submit = function (params, cb) {
|
|
|
30019
30069
|
request.removeListener('error', callback);
|
|
30020
30070
|
request.removeListener('response', onResponse);
|
|
30021
30071
|
|
|
30022
|
-
return cb.call(this, error, responce);
|
|
30072
|
+
return cb.call(this, error, responce);
|
|
30023
30073
|
};
|
|
30024
30074
|
|
|
30025
30075
|
onResponse = callback.bind(this, null);
|
|
@@ -30043,7 +30093,7 @@ FormData$1.prototype._error = function (err) {
|
|
|
30043
30093
|
FormData$1.prototype.toString = function () {
|
|
30044
30094
|
return '[object FormData]';
|
|
30045
30095
|
};
|
|
30046
|
-
setToStringTag(FormData$1, 'FormData');
|
|
30096
|
+
setToStringTag(FormData$1.prototype, 'FormData');
|
|
30047
30097
|
|
|
30048
30098
|
// Public API
|
|
30049
30099
|
var form_data = FormData$1;
|
|
@@ -30128,7 +30178,7 @@ const predicates = utils$1.toFlatObject(utils$1, {}, null, function filter(prop)
|
|
|
30128
30178
|
*
|
|
30129
30179
|
* @returns
|
|
30130
30180
|
*/
|
|
30131
|
-
function toFormData(obj, formData, options) {
|
|
30181
|
+
function toFormData$1(obj, formData, options) {
|
|
30132
30182
|
if (!utils$1.isObject(obj)) {
|
|
30133
30183
|
throw new TypeError('target must be an object');
|
|
30134
30184
|
}
|
|
@@ -30170,7 +30220,7 @@ function toFormData(obj, formData, options) {
|
|
|
30170
30220
|
}
|
|
30171
30221
|
|
|
30172
30222
|
if (!useBlob && utils$1.isBlob(value)) {
|
|
30173
|
-
throw new AxiosError('Blob is not supported. Use a Buffer instead.');
|
|
30223
|
+
throw new AxiosError$1('Blob is not supported. Use a Buffer instead.');
|
|
30174
30224
|
}
|
|
30175
30225
|
|
|
30176
30226
|
if (utils$1.isArrayBuffer(value) || utils$1.isTypedArray(value)) {
|
|
@@ -30299,7 +30349,7 @@ function encode$1(str) {
|
|
|
30299
30349
|
function AxiosURLSearchParams(params, options) {
|
|
30300
30350
|
this._pairs = [];
|
|
30301
30351
|
|
|
30302
|
-
params && toFormData(params, this, options);
|
|
30352
|
+
params && toFormData$1(params, this, options);
|
|
30303
30353
|
}
|
|
30304
30354
|
|
|
30305
30355
|
const prototype = AxiosURLSearchParams.prototype;
|
|
@@ -30344,29 +30394,26 @@ function encode(val) {
|
|
|
30344
30394
|
* @returns {string} The formatted url
|
|
30345
30395
|
*/
|
|
30346
30396
|
function buildURL(url, params, options) {
|
|
30347
|
-
/*eslint no-param-reassign:0*/
|
|
30348
30397
|
if (!params) {
|
|
30349
30398
|
return url;
|
|
30350
30399
|
}
|
|
30351
|
-
|
|
30400
|
+
|
|
30352
30401
|
const _encode = options && options.encode || encode;
|
|
30353
30402
|
|
|
30354
|
-
|
|
30355
|
-
options
|
|
30356
|
-
|
|
30357
|
-
};
|
|
30358
|
-
}
|
|
30403
|
+
const _options = utils$1.isFunction(options) ? {
|
|
30404
|
+
serialize: options
|
|
30405
|
+
} : options;
|
|
30359
30406
|
|
|
30360
|
-
const serializeFn =
|
|
30407
|
+
const serializeFn = _options && _options.serialize;
|
|
30361
30408
|
|
|
30362
30409
|
let serializedParams;
|
|
30363
30410
|
|
|
30364
30411
|
if (serializeFn) {
|
|
30365
|
-
serializedParams = serializeFn(params,
|
|
30412
|
+
serializedParams = serializeFn(params, _options);
|
|
30366
30413
|
} else {
|
|
30367
30414
|
serializedParams = utils$1.isURLSearchParams(params) ?
|
|
30368
30415
|
params.toString() :
|
|
30369
|
-
new AxiosURLSearchParams(params,
|
|
30416
|
+
new AxiosURLSearchParams(params, _options).toString(_encode);
|
|
30370
30417
|
}
|
|
30371
30418
|
|
|
30372
30419
|
if (serializedParams) {
|
|
@@ -30391,6 +30438,7 @@ class InterceptorManager {
|
|
|
30391
30438
|
*
|
|
30392
30439
|
* @param {Function} fulfilled The function to handle `then` for a `Promise`
|
|
30393
30440
|
* @param {Function} rejected The function to handle `reject` for a `Promise`
|
|
30441
|
+
* @param {Object} options The options for the interceptor, synchronous and runWhen
|
|
30394
30442
|
*
|
|
30395
30443
|
* @return {Number} An ID used to remove interceptor later
|
|
30396
30444
|
*/
|
|
@@ -30409,7 +30457,7 @@ class InterceptorManager {
|
|
|
30409
30457
|
*
|
|
30410
30458
|
* @param {Number} id The ID that was returned by `use`
|
|
30411
30459
|
*
|
|
30412
|
-
* @returns {
|
|
30460
|
+
* @returns {void}
|
|
30413
30461
|
*/
|
|
30414
30462
|
eject(id) {
|
|
30415
30463
|
if (this.handlers[id]) {
|
|
@@ -30450,7 +30498,8 @@ class InterceptorManager {
|
|
|
30450
30498
|
var transitionalDefaults = {
|
|
30451
30499
|
silentJSONParsing: true,
|
|
30452
30500
|
forcedJSONParsing: true,
|
|
30453
|
-
clarifyTimeoutError: false
|
|
30501
|
+
clarifyTimeoutError: false,
|
|
30502
|
+
legacyInterceptorReqResOrdering: true
|
|
30454
30503
|
};
|
|
30455
30504
|
|
|
30456
30505
|
var URLSearchParams = require$$0$5.URLSearchParams;
|
|
@@ -30549,7 +30598,7 @@ var platform = {
|
|
|
30549
30598
|
};
|
|
30550
30599
|
|
|
30551
30600
|
function toURLEncodedForm(data, options) {
|
|
30552
|
-
return toFormData(data, new platform.classes.URLSearchParams(), {
|
|
30601
|
+
return toFormData$1(data, new platform.classes.URLSearchParams(), {
|
|
30553
30602
|
visitor: function(value, key, path, helpers) {
|
|
30554
30603
|
if (platform.isNode && utils$1.isBuffer(value)) {
|
|
30555
30604
|
this.append(key, value.toString('base64'));
|
|
@@ -30674,7 +30723,7 @@ function stringifySafely(rawValue, parser, encoder) {
|
|
|
30674
30723
|
}
|
|
30675
30724
|
}
|
|
30676
30725
|
|
|
30677
|
-
return (
|
|
30726
|
+
return (encoder || JSON.stringify)(rawValue);
|
|
30678
30727
|
}
|
|
30679
30728
|
|
|
30680
30729
|
const defaults = {
|
|
@@ -30725,7 +30774,7 @@ const defaults = {
|
|
|
30725
30774
|
if ((isFileList = utils$1.isFileList(data)) || contentType.indexOf('multipart/form-data') > -1) {
|
|
30726
30775
|
const _FormData = this.env && this.env.FormData;
|
|
30727
30776
|
|
|
30728
|
-
return toFormData(
|
|
30777
|
+
return toFormData$1(
|
|
30729
30778
|
isFileList ? {'files[]': data} : data,
|
|
30730
30779
|
_FormData && new _FormData(),
|
|
30731
30780
|
this.formSerializer
|
|
@@ -30759,7 +30808,7 @@ const defaults = {
|
|
|
30759
30808
|
} catch (e) {
|
|
30760
30809
|
if (strictJSONParsing) {
|
|
30761
30810
|
if (e.name === 'SyntaxError') {
|
|
30762
|
-
throw AxiosError.from(e, AxiosError.ERR_BAD_RESPONSE, this, null, this.response);
|
|
30811
|
+
throw AxiosError$1.from(e, AxiosError$1.ERR_BAD_RESPONSE, this, null, this.response);
|
|
30763
30812
|
}
|
|
30764
30813
|
throw e;
|
|
30765
30814
|
}
|
|
@@ -30922,7 +30971,7 @@ function buildAccessors(obj, header) {
|
|
|
30922
30971
|
});
|
|
30923
30972
|
}
|
|
30924
30973
|
|
|
30925
|
-
class AxiosHeaders {
|
|
30974
|
+
let AxiosHeaders$1 = class AxiosHeaders {
|
|
30926
30975
|
constructor(headers) {
|
|
30927
30976
|
headers && this.set(headers);
|
|
30928
30977
|
}
|
|
@@ -31145,12 +31194,12 @@ class AxiosHeaders {
|
|
|
31145
31194
|
|
|
31146
31195
|
return this;
|
|
31147
31196
|
}
|
|
31148
|
-
}
|
|
31197
|
+
};
|
|
31149
31198
|
|
|
31150
|
-
AxiosHeaders.accessor(['Content-Type', 'Content-Length', 'Accept', 'Accept-Encoding', 'User-Agent', 'Authorization']);
|
|
31199
|
+
AxiosHeaders$1.accessor(['Content-Type', 'Content-Length', 'Accept', 'Accept-Encoding', 'User-Agent', 'Authorization']);
|
|
31151
31200
|
|
|
31152
31201
|
// reserved names hotfix
|
|
31153
|
-
utils$1.reduceDescriptors(AxiosHeaders.prototype, ({value}, key) => {
|
|
31202
|
+
utils$1.reduceDescriptors(AxiosHeaders$1.prototype, ({value}, key) => {
|
|
31154
31203
|
let mapped = key[0].toUpperCase() + key.slice(1); // map `set` => `Set`
|
|
31155
31204
|
return {
|
|
31156
31205
|
get: () => value,
|
|
@@ -31160,7 +31209,7 @@ utils$1.reduceDescriptors(AxiosHeaders.prototype, ({value}, key) => {
|
|
|
31160
31209
|
}
|
|
31161
31210
|
});
|
|
31162
31211
|
|
|
31163
|
-
utils$1.freezeMethods(AxiosHeaders);
|
|
31212
|
+
utils$1.freezeMethods(AxiosHeaders$1);
|
|
31164
31213
|
|
|
31165
31214
|
/**
|
|
31166
31215
|
* Transform the data for a request or a response
|
|
@@ -31173,7 +31222,7 @@ utils$1.freezeMethods(AxiosHeaders);
|
|
|
31173
31222
|
function transformData(fns, response) {
|
|
31174
31223
|
const config = this || defaults;
|
|
31175
31224
|
const context = response || config;
|
|
31176
|
-
const headers = AxiosHeaders.from(context.headers);
|
|
31225
|
+
const headers = AxiosHeaders$1.from(context.headers);
|
|
31177
31226
|
let data = context.data;
|
|
31178
31227
|
|
|
31179
31228
|
utils$1.forEach(fns, function transform(fn) {
|
|
@@ -31185,28 +31234,26 @@ function transformData(fns, response) {
|
|
|
31185
31234
|
return data;
|
|
31186
31235
|
}
|
|
31187
31236
|
|
|
31188
|
-
function isCancel(value) {
|
|
31237
|
+
function isCancel$1(value) {
|
|
31189
31238
|
return !!(value && value.__CANCEL__);
|
|
31190
31239
|
}
|
|
31191
31240
|
|
|
31192
|
-
|
|
31193
|
-
|
|
31194
|
-
|
|
31195
|
-
|
|
31196
|
-
|
|
31197
|
-
|
|
31198
|
-
|
|
31199
|
-
|
|
31200
|
-
|
|
31201
|
-
|
|
31202
|
-
|
|
31203
|
-
|
|
31204
|
-
|
|
31205
|
-
|
|
31206
|
-
|
|
31207
|
-
|
|
31208
|
-
__CANCEL__: true
|
|
31209
|
-
});
|
|
31241
|
+
let CanceledError$1 = class CanceledError extends AxiosError$1 {
|
|
31242
|
+
/**
|
|
31243
|
+
* A `CanceledError` is an object that is thrown when an operation is canceled.
|
|
31244
|
+
*
|
|
31245
|
+
* @param {string=} message The message.
|
|
31246
|
+
* @param {Object=} config The config.
|
|
31247
|
+
* @param {Object=} request The request.
|
|
31248
|
+
*
|
|
31249
|
+
* @returns {CanceledError} The created error.
|
|
31250
|
+
*/
|
|
31251
|
+
constructor(message, config, request) {
|
|
31252
|
+
super(message == null ? 'canceled' : message, AxiosError$1.ERR_CANCELED, config, request);
|
|
31253
|
+
this.name = 'CanceledError';
|
|
31254
|
+
this.__CANCEL__ = true;
|
|
31255
|
+
}
|
|
31256
|
+
};
|
|
31210
31257
|
|
|
31211
31258
|
/**
|
|
31212
31259
|
* Resolve or reject a Promise based on response status.
|
|
@@ -31222,9 +31269,9 @@ function settle(resolve, reject, response) {
|
|
|
31222
31269
|
if (!response.status || !validateStatus || validateStatus(response.status)) {
|
|
31223
31270
|
resolve(response);
|
|
31224
31271
|
} else {
|
|
31225
|
-
reject(new AxiosError(
|
|
31272
|
+
reject(new AxiosError$1(
|
|
31226
31273
|
'Request failed with status code ' + response.status,
|
|
31227
|
-
[AxiosError.ERR_BAD_REQUEST, AxiosError.ERR_BAD_RESPONSE][Math.floor(response.status / 100) - 4],
|
|
31274
|
+
[AxiosError$1.ERR_BAD_REQUEST, AxiosError$1.ERR_BAD_RESPONSE][Math.floor(response.status / 100) - 4],
|
|
31228
31275
|
response.config,
|
|
31229
31276
|
response.request,
|
|
31230
31277
|
response
|
|
@@ -31243,6 +31290,10 @@ function isAbsoluteURL(url) {
|
|
|
31243
31290
|
// A URL is considered absolute if it begins with "<scheme>://" or "//" (protocol-relative URL).
|
|
31244
31291
|
// RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed
|
|
31245
31292
|
// by any combination of letters, digits, plus, period, or hyphen.
|
|
31293
|
+
if (typeof url !== 'string') {
|
|
31294
|
+
return false;
|
|
31295
|
+
}
|
|
31296
|
+
|
|
31246
31297
|
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(url);
|
|
31247
31298
|
}
|
|
31248
31299
|
|
|
@@ -31904,7 +31955,7 @@ RedirectableRequest.prototype._processResponse = function (response) {
|
|
|
31904
31955
|
// Wraps the key/value object of protocols with redirect functionality
|
|
31905
31956
|
function wrap(protocols) {
|
|
31906
31957
|
// Default settings
|
|
31907
|
-
var exports = {
|
|
31958
|
+
var exports$1 = {
|
|
31908
31959
|
maxRedirects: 21,
|
|
31909
31960
|
maxBodyLength: 10 * 1024 * 1024,
|
|
31910
31961
|
};
|
|
@@ -31914,7 +31965,7 @@ function wrap(protocols) {
|
|
|
31914
31965
|
Object.keys(protocols).forEach(function (scheme) {
|
|
31915
31966
|
var protocol = scheme + ":";
|
|
31916
31967
|
var nativeProtocol = nativeProtocols[protocol] = protocols[scheme];
|
|
31917
|
-
var wrappedProtocol = exports[scheme] = Object.create(nativeProtocol);
|
|
31968
|
+
var wrappedProtocol = exports$1[scheme] = Object.create(nativeProtocol);
|
|
31918
31969
|
|
|
31919
31970
|
// Executes a request, following redirects
|
|
31920
31971
|
function request(input, options, callback) {
|
|
@@ -31937,8 +31988,8 @@ function wrap(protocols) {
|
|
|
31937
31988
|
|
|
31938
31989
|
// Set defaults
|
|
31939
31990
|
options = Object.assign({
|
|
31940
|
-
maxRedirects: exports.maxRedirects,
|
|
31941
|
-
maxBodyLength: exports.maxBodyLength,
|
|
31991
|
+
maxRedirects: exports$1.maxRedirects,
|
|
31992
|
+
maxBodyLength: exports$1.maxBodyLength,
|
|
31942
31993
|
}, input, options);
|
|
31943
31994
|
options.nativeProtocols = nativeProtocols;
|
|
31944
31995
|
if (!isString(options.host) && !isString(options.hostname)) {
|
|
@@ -31963,7 +32014,7 @@ function wrap(protocols) {
|
|
|
31963
32014
|
get: { value: get, configurable: true, enumerable: true, writable: true },
|
|
31964
32015
|
});
|
|
31965
32016
|
});
|
|
31966
|
-
return exports;
|
|
32017
|
+
return exports$1;
|
|
31967
32018
|
}
|
|
31968
32019
|
|
|
31969
32020
|
function noop() { /* empty */ }
|
|
@@ -32095,7 +32146,7 @@ followRedirects$1.exports.wrap = wrap;
|
|
|
32095
32146
|
var followRedirectsExports = followRedirects$1.exports;
|
|
32096
32147
|
var followRedirects = /*@__PURE__*/getDefaultExportFromCjs(followRedirectsExports);
|
|
32097
32148
|
|
|
32098
|
-
const VERSION = "1.
|
|
32149
|
+
const VERSION$1 = "1.13.5";
|
|
32099
32150
|
|
|
32100
32151
|
function parseProtocol(url) {
|
|
32101
32152
|
const match = /^([-+\w]{1,25})(:?\/\/|:)/.exec(url);
|
|
@@ -32128,7 +32179,7 @@ function fromDataURI(uri, asBlob, options) {
|
|
|
32128
32179
|
const match = DATA_URL_PATTERN.exec(uri);
|
|
32129
32180
|
|
|
32130
32181
|
if (!match) {
|
|
32131
|
-
throw new AxiosError('Invalid URL', AxiosError.ERR_INVALID_URL);
|
|
32182
|
+
throw new AxiosError$1('Invalid URL', AxiosError$1.ERR_INVALID_URL);
|
|
32132
32183
|
}
|
|
32133
32184
|
|
|
32134
32185
|
const mime = match[1];
|
|
@@ -32138,7 +32189,7 @@ function fromDataURI(uri, asBlob, options) {
|
|
|
32138
32189
|
|
|
32139
32190
|
if (asBlob) {
|
|
32140
32191
|
if (!_Blob) {
|
|
32141
|
-
throw new AxiosError('Blob is not supported', AxiosError.ERR_NOT_SUPPORT);
|
|
32192
|
+
throw new AxiosError$1('Blob is not supported', AxiosError$1.ERR_NOT_SUPPORT);
|
|
32142
32193
|
}
|
|
32143
32194
|
|
|
32144
32195
|
return new _Blob([buffer], {type: mime});
|
|
@@ -32147,7 +32198,7 @@ function fromDataURI(uri, asBlob, options) {
|
|
|
32147
32198
|
return buffer;
|
|
32148
32199
|
}
|
|
32149
32200
|
|
|
32150
|
-
throw new AxiosError('Unsupported protocol ' + protocol, AxiosError.ERR_NOT_SUPPORT);
|
|
32201
|
+
throw new AxiosError$1('Unsupported protocol ' + protocol, AxiosError$1.ERR_NOT_SUPPORT);
|
|
32151
32202
|
}
|
|
32152
32203
|
|
|
32153
32204
|
const kInternals = Symbol('internals');
|
|
@@ -32303,7 +32354,7 @@ const readBlob = async function* (blob) {
|
|
|
32303
32354
|
|
|
32304
32355
|
const BOUNDARY_ALPHABET = platform.ALPHABET.ALPHA_DIGIT + '-_';
|
|
32305
32356
|
|
|
32306
|
-
const textEncoder = typeof TextEncoder === 'function' ? new TextEncoder() : new
|
|
32357
|
+
const textEncoder = typeof TextEncoder === 'function' ? new TextEncoder() : new util$3.TextEncoder();
|
|
32307
32358
|
|
|
32308
32359
|
const CRLF = '\r\n';
|
|
32309
32360
|
const CRLF_BYTES = textEncoder.encode(CRLF);
|
|
@@ -32681,6 +32732,101 @@ const flushOnFinish = (stream, [throttled, flush]) => {
|
|
|
32681
32732
|
return throttled;
|
|
32682
32733
|
};
|
|
32683
32734
|
|
|
32735
|
+
class Http2Sessions {
|
|
32736
|
+
constructor() {
|
|
32737
|
+
this.sessions = Object.create(null);
|
|
32738
|
+
}
|
|
32739
|
+
|
|
32740
|
+
getSession(authority, options) {
|
|
32741
|
+
options = Object.assign({
|
|
32742
|
+
sessionTimeout: 1000
|
|
32743
|
+
}, options);
|
|
32744
|
+
|
|
32745
|
+
let authoritySessions = this.sessions[authority];
|
|
32746
|
+
|
|
32747
|
+
if (authoritySessions) {
|
|
32748
|
+
let len = authoritySessions.length;
|
|
32749
|
+
|
|
32750
|
+
for (let i = 0; i < len; i++) {
|
|
32751
|
+
const [sessionHandle, sessionOptions] = authoritySessions[i];
|
|
32752
|
+
if (!sessionHandle.destroyed && !sessionHandle.closed && util$3.isDeepStrictEqual(sessionOptions, options)) {
|
|
32753
|
+
return sessionHandle;
|
|
32754
|
+
}
|
|
32755
|
+
}
|
|
32756
|
+
}
|
|
32757
|
+
|
|
32758
|
+
const session = http2.connect(authority, options);
|
|
32759
|
+
|
|
32760
|
+
let removed;
|
|
32761
|
+
|
|
32762
|
+
const removeSession = () => {
|
|
32763
|
+
if (removed) {
|
|
32764
|
+
return;
|
|
32765
|
+
}
|
|
32766
|
+
|
|
32767
|
+
removed = true;
|
|
32768
|
+
|
|
32769
|
+
let entries = authoritySessions, len = entries.length, i = len;
|
|
32770
|
+
|
|
32771
|
+
while (i--) {
|
|
32772
|
+
if (entries[i][0] === session) {
|
|
32773
|
+
if (len === 1) {
|
|
32774
|
+
delete this.sessions[authority];
|
|
32775
|
+
} else {
|
|
32776
|
+
entries.splice(i, 1);
|
|
32777
|
+
}
|
|
32778
|
+
return;
|
|
32779
|
+
}
|
|
32780
|
+
}
|
|
32781
|
+
};
|
|
32782
|
+
|
|
32783
|
+
const originalRequestFn = session.request;
|
|
32784
|
+
|
|
32785
|
+
const {sessionTimeout} = options;
|
|
32786
|
+
|
|
32787
|
+
if(sessionTimeout != null) {
|
|
32788
|
+
|
|
32789
|
+
let timer;
|
|
32790
|
+
let streamsCount = 0;
|
|
32791
|
+
|
|
32792
|
+
session.request = function () {
|
|
32793
|
+
const stream = originalRequestFn.apply(this, arguments);
|
|
32794
|
+
|
|
32795
|
+
streamsCount++;
|
|
32796
|
+
|
|
32797
|
+
if (timer) {
|
|
32798
|
+
clearTimeout(timer);
|
|
32799
|
+
timer = null;
|
|
32800
|
+
}
|
|
32801
|
+
|
|
32802
|
+
stream.once('close', () => {
|
|
32803
|
+
if (!--streamsCount) {
|
|
32804
|
+
timer = setTimeout(() => {
|
|
32805
|
+
timer = null;
|
|
32806
|
+
removeSession();
|
|
32807
|
+
}, sessionTimeout);
|
|
32808
|
+
}
|
|
32809
|
+
});
|
|
32810
|
+
|
|
32811
|
+
return stream;
|
|
32812
|
+
};
|
|
32813
|
+
}
|
|
32814
|
+
|
|
32815
|
+
session.once('close', removeSession);
|
|
32816
|
+
|
|
32817
|
+
let entry = [
|
|
32818
|
+
session,
|
|
32819
|
+
options
|
|
32820
|
+
];
|
|
32821
|
+
|
|
32822
|
+
authoritySessions ? authoritySessions.push(entry) : authoritySessions = this.sessions[authority] = [entry];
|
|
32823
|
+
|
|
32824
|
+
return session;
|
|
32825
|
+
}
|
|
32826
|
+
}
|
|
32827
|
+
|
|
32828
|
+
const http2Sessions = new Http2Sessions();
|
|
32829
|
+
|
|
32684
32830
|
|
|
32685
32831
|
/**
|
|
32686
32832
|
* If the proxy or config beforeRedirects functions are defined, call them with the options
|
|
@@ -32724,12 +32870,16 @@ function setProxy(options, configProxy, location) {
|
|
|
32724
32870
|
|
|
32725
32871
|
if (proxy.auth) {
|
|
32726
32872
|
// Support proxy auth object form
|
|
32727
|
-
|
|
32873
|
+
const validProxyAuth = Boolean(proxy.auth.username || proxy.auth.password);
|
|
32874
|
+
|
|
32875
|
+
if (validProxyAuth) {
|
|
32728
32876
|
proxy.auth = (proxy.auth.username || '') + ':' + (proxy.auth.password || '');
|
|
32877
|
+
} else if (typeof proxy.auth === 'object') {
|
|
32878
|
+
throw new AxiosError$1('Invalid proxy authorization', AxiosError$1.ERR_BAD_OPTION, { proxy });
|
|
32729
32879
|
}
|
|
32730
|
-
|
|
32731
|
-
|
|
32732
|
-
|
|
32880
|
+
|
|
32881
|
+
const base64 = Buffer.from(proxy.auth, 'utf8').toString('base64');
|
|
32882
|
+
|
|
32733
32883
|
options.headers['Proxy-Authorization'] = 'Basic ' + base64;
|
|
32734
32884
|
}
|
|
32735
32885
|
|
|
@@ -32793,16 +32943,76 @@ const resolveFamily = ({address, family}) => {
|
|
|
32793
32943
|
|
|
32794
32944
|
const buildAddressEntry = (address, family) => resolveFamily(utils$1.isObject(address) ? address : {address, family});
|
|
32795
32945
|
|
|
32946
|
+
const http2Transport = {
|
|
32947
|
+
request(options, cb) {
|
|
32948
|
+
const authority = options.protocol + '//' + options.hostname + ':' + (options.port ||(options.protocol === 'https:' ? 443 : 80));
|
|
32949
|
+
|
|
32950
|
+
|
|
32951
|
+
const {http2Options, headers} = options;
|
|
32952
|
+
|
|
32953
|
+
const session = http2Sessions.getSession(authority, http2Options);
|
|
32954
|
+
|
|
32955
|
+
const {
|
|
32956
|
+
HTTP2_HEADER_SCHEME,
|
|
32957
|
+
HTTP2_HEADER_METHOD,
|
|
32958
|
+
HTTP2_HEADER_PATH,
|
|
32959
|
+
HTTP2_HEADER_STATUS
|
|
32960
|
+
} = http2.constants;
|
|
32961
|
+
|
|
32962
|
+
const http2Headers = {
|
|
32963
|
+
[HTTP2_HEADER_SCHEME]: options.protocol.replace(':', ''),
|
|
32964
|
+
[HTTP2_HEADER_METHOD]: options.method,
|
|
32965
|
+
[HTTP2_HEADER_PATH]: options.path,
|
|
32966
|
+
};
|
|
32967
|
+
|
|
32968
|
+
utils$1.forEach(headers, (header, name) => {
|
|
32969
|
+
name.charAt(0) !== ':' && (http2Headers[name] = header);
|
|
32970
|
+
});
|
|
32971
|
+
|
|
32972
|
+
const req = session.request(http2Headers);
|
|
32973
|
+
|
|
32974
|
+
req.once('response', (responseHeaders) => {
|
|
32975
|
+
const response = req; //duplex
|
|
32976
|
+
|
|
32977
|
+
responseHeaders = Object.assign({}, responseHeaders);
|
|
32978
|
+
|
|
32979
|
+
const status = responseHeaders[HTTP2_HEADER_STATUS];
|
|
32980
|
+
|
|
32981
|
+
delete responseHeaders[HTTP2_HEADER_STATUS];
|
|
32982
|
+
|
|
32983
|
+
response.headers = responseHeaders;
|
|
32984
|
+
|
|
32985
|
+
response.statusCode = +status;
|
|
32986
|
+
|
|
32987
|
+
cb(response);
|
|
32988
|
+
});
|
|
32989
|
+
|
|
32990
|
+
return req;
|
|
32991
|
+
}
|
|
32992
|
+
};
|
|
32993
|
+
|
|
32796
32994
|
/*eslint consistent-return:0*/
|
|
32797
32995
|
var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
32798
32996
|
return wrapAsync(async function dispatchHttpRequest(resolve, reject, onDone) {
|
|
32799
|
-
let {data, lookup, family} = config;
|
|
32997
|
+
let {data, lookup, family, httpVersion = 1, http2Options} = config;
|
|
32800
32998
|
const {responseType, responseEncoding} = config;
|
|
32801
32999
|
const method = config.method.toUpperCase();
|
|
32802
33000
|
let isDone;
|
|
32803
33001
|
let rejected = false;
|
|
32804
33002
|
let req;
|
|
32805
33003
|
|
|
33004
|
+
httpVersion = +httpVersion;
|
|
33005
|
+
|
|
33006
|
+
if (Number.isNaN(httpVersion)) {
|
|
33007
|
+
throw TypeError(`Invalid protocol version: '${config.httpVersion}' is not a number`);
|
|
33008
|
+
}
|
|
33009
|
+
|
|
33010
|
+
if (httpVersion !== 1 && httpVersion !== 2) {
|
|
33011
|
+
throw TypeError(`Unsupported protocol version '${httpVersion}'`);
|
|
33012
|
+
}
|
|
33013
|
+
|
|
33014
|
+
const isHttp2 = httpVersion === 2;
|
|
33015
|
+
|
|
32806
33016
|
if (lookup) {
|
|
32807
33017
|
const _lookup = callbackify(lookup, (value) => utils$1.isArray(value) ? value : [value]);
|
|
32808
33018
|
// hotfix to support opt.all option which is required for node 20.x
|
|
@@ -32819,8 +33029,17 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
32819
33029
|
};
|
|
32820
33030
|
}
|
|
32821
33031
|
|
|
32822
|
-
|
|
32823
|
-
|
|
33032
|
+
const abortEmitter = new EventEmitter$1();
|
|
33033
|
+
|
|
33034
|
+
function abort(reason) {
|
|
33035
|
+
try {
|
|
33036
|
+
abortEmitter.emit('abort', !reason || reason.type ? new CanceledError$1(null, config, req) : reason);
|
|
33037
|
+
} catch(err) {
|
|
33038
|
+
console.warn('emit error', err);
|
|
33039
|
+
}
|
|
33040
|
+
}
|
|
33041
|
+
|
|
33042
|
+
abortEmitter.once('abort', reject);
|
|
32824
33043
|
|
|
32825
33044
|
const onFinished = () => {
|
|
32826
33045
|
if (config.cancelToken) {
|
|
@@ -32831,29 +33050,40 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
32831
33050
|
config.signal.removeEventListener('abort', abort);
|
|
32832
33051
|
}
|
|
32833
33052
|
|
|
32834
|
-
|
|
33053
|
+
abortEmitter.removeAllListeners();
|
|
32835
33054
|
};
|
|
32836
33055
|
|
|
32837
|
-
|
|
33056
|
+
if (config.cancelToken || config.signal) {
|
|
33057
|
+
config.cancelToken && config.cancelToken.subscribe(abort);
|
|
33058
|
+
if (config.signal) {
|
|
33059
|
+
config.signal.aborted ? abort() : config.signal.addEventListener('abort', abort);
|
|
33060
|
+
}
|
|
33061
|
+
}
|
|
33062
|
+
|
|
33063
|
+
onDone((response, isRejected) => {
|
|
32838
33064
|
isDone = true;
|
|
33065
|
+
|
|
32839
33066
|
if (isRejected) {
|
|
32840
33067
|
rejected = true;
|
|
32841
33068
|
onFinished();
|
|
33069
|
+
return;
|
|
33070
|
+
}
|
|
33071
|
+
|
|
33072
|
+
const {data} = response;
|
|
33073
|
+
|
|
33074
|
+
if (data instanceof stream.Readable || data instanceof stream.Duplex) {
|
|
33075
|
+
const offListeners = stream.finished(data, () => {
|
|
33076
|
+
offListeners();
|
|
33077
|
+
onFinished();
|
|
33078
|
+
});
|
|
33079
|
+
} else {
|
|
33080
|
+
onFinished();
|
|
32842
33081
|
}
|
|
32843
33082
|
});
|
|
32844
33083
|
|
|
32845
|
-
function abort(reason) {
|
|
32846
|
-
emitter.emit('abort', !reason || reason.type ? new CanceledError(null, config, req) : reason);
|
|
32847
|
-
}
|
|
32848
33084
|
|
|
32849
|
-
emitter.once('abort', reject);
|
|
32850
33085
|
|
|
32851
|
-
|
|
32852
|
-
config.cancelToken && config.cancelToken.subscribe(abort);
|
|
32853
|
-
if (config.signal) {
|
|
32854
|
-
config.signal.aborted ? abort() : config.signal.addEventListener('abort', abort);
|
|
32855
|
-
}
|
|
32856
|
-
}
|
|
33086
|
+
|
|
32857
33087
|
|
|
32858
33088
|
// Parse url
|
|
32859
33089
|
const fullPath = buildFullPath(config.baseURL, config.url, config.allowAbsoluteUrls);
|
|
@@ -32868,9 +33098,9 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
32868
33098
|
const estimated = estimateDataURLDecodedBytes(dataUrl);
|
|
32869
33099
|
|
|
32870
33100
|
if (estimated > config.maxContentLength) {
|
|
32871
|
-
return reject(new AxiosError(
|
|
33101
|
+
return reject(new AxiosError$1(
|
|
32872
33102
|
'maxContentLength size of ' + config.maxContentLength + ' exceeded',
|
|
32873
|
-
AxiosError.ERR_BAD_RESPONSE,
|
|
33103
|
+
AxiosError$1.ERR_BAD_RESPONSE,
|
|
32874
33104
|
config
|
|
32875
33105
|
));
|
|
32876
33106
|
}
|
|
@@ -32892,7 +33122,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
32892
33122
|
Blob: config.env && config.env.Blob
|
|
32893
33123
|
});
|
|
32894
33124
|
} catch (err) {
|
|
32895
|
-
throw AxiosError.from(err, AxiosError.ERR_BAD_REQUEST, config);
|
|
33125
|
+
throw AxiosError$1.from(err, AxiosError$1.ERR_BAD_REQUEST, config);
|
|
32896
33126
|
}
|
|
32897
33127
|
|
|
32898
33128
|
if (responseType === 'text') {
|
|
@@ -32909,26 +33139,26 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
32909
33139
|
data: convertedData,
|
|
32910
33140
|
status: 200,
|
|
32911
33141
|
statusText: 'OK',
|
|
32912
|
-
headers: new AxiosHeaders(),
|
|
33142
|
+
headers: new AxiosHeaders$1(),
|
|
32913
33143
|
config
|
|
32914
33144
|
});
|
|
32915
33145
|
}
|
|
32916
33146
|
|
|
32917
33147
|
if (supportedProtocols.indexOf(protocol) === -1) {
|
|
32918
|
-
return reject(new AxiosError(
|
|
33148
|
+
return reject(new AxiosError$1(
|
|
32919
33149
|
'Unsupported protocol ' + protocol,
|
|
32920
|
-
AxiosError.ERR_BAD_REQUEST,
|
|
33150
|
+
AxiosError$1.ERR_BAD_REQUEST,
|
|
32921
33151
|
config
|
|
32922
33152
|
));
|
|
32923
33153
|
}
|
|
32924
33154
|
|
|
32925
|
-
const headers = AxiosHeaders.from(config.headers).normalize();
|
|
33155
|
+
const headers = AxiosHeaders$1.from(config.headers).normalize();
|
|
32926
33156
|
|
|
32927
33157
|
// Set User-Agent (required by some servers)
|
|
32928
33158
|
// See https://github.com/axios/axios/issues/69
|
|
32929
33159
|
// User-Agent is specified; handle case where no UA header is desired
|
|
32930
33160
|
// Only set header if it hasn't been set in config
|
|
32931
|
-
headers.set('User-Agent', 'axios/' + VERSION, false);
|
|
33161
|
+
headers.set('User-Agent', 'axios/' + VERSION$1, false);
|
|
32932
33162
|
|
|
32933
33163
|
const {onUploadProgress, onDownloadProgress} = config;
|
|
32934
33164
|
const maxRate = config.maxRate;
|
|
@@ -32942,7 +33172,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
32942
33172
|
data = formDataToStream(data, (formHeaders) => {
|
|
32943
33173
|
headers.set(formHeaders);
|
|
32944
33174
|
}, {
|
|
32945
|
-
tag: `axios-${VERSION}-boundary`,
|
|
33175
|
+
tag: `axios-${VERSION$1}-boundary`,
|
|
32946
33176
|
boundary: userBoundary && userBoundary[1] || undefined
|
|
32947
33177
|
});
|
|
32948
33178
|
// support for https://www.npmjs.com/package/form-data api
|
|
@@ -32951,7 +33181,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
32951
33181
|
|
|
32952
33182
|
if (!headers.hasContentLength()) {
|
|
32953
33183
|
try {
|
|
32954
|
-
const knownLength = await
|
|
33184
|
+
const knownLength = await util$3.promisify(data.getLength).call(data);
|
|
32955
33185
|
Number.isFinite(knownLength) && knownLength >= 0 && headers.setContentLength(knownLength);
|
|
32956
33186
|
/*eslint no-empty:0*/
|
|
32957
33187
|
} catch (e) {
|
|
@@ -32967,9 +33197,9 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
32967
33197
|
} else if (utils$1.isString(data)) {
|
|
32968
33198
|
data = Buffer.from(data, 'utf-8');
|
|
32969
33199
|
} else {
|
|
32970
|
-
return reject(new AxiosError(
|
|
33200
|
+
return reject(new AxiosError$1(
|
|
32971
33201
|
'Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream',
|
|
32972
|
-
AxiosError.ERR_BAD_REQUEST,
|
|
33202
|
+
AxiosError$1.ERR_BAD_REQUEST,
|
|
32973
33203
|
config
|
|
32974
33204
|
));
|
|
32975
33205
|
}
|
|
@@ -32978,9 +33208,9 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
32978
33208
|
headers.setContentLength(data.length, false);
|
|
32979
33209
|
|
|
32980
33210
|
if (config.maxBodyLength > -1 && data.length > config.maxBodyLength) {
|
|
32981
|
-
return reject(new AxiosError(
|
|
33211
|
+
return reject(new AxiosError$1(
|
|
32982
33212
|
'Request body larger than maxBodyLength limit',
|
|
32983
|
-
AxiosError.ERR_BAD_REQUEST,
|
|
33213
|
+
AxiosError$1.ERR_BAD_REQUEST,
|
|
32984
33214
|
config
|
|
32985
33215
|
));
|
|
32986
33216
|
}
|
|
@@ -33059,7 +33289,8 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33059
33289
|
protocol,
|
|
33060
33290
|
family,
|
|
33061
33291
|
beforeRedirect: dispatchBeforeRedirect,
|
|
33062
|
-
beforeRedirects: {}
|
|
33292
|
+
beforeRedirects: {},
|
|
33293
|
+
http2Options
|
|
33063
33294
|
};
|
|
33064
33295
|
|
|
33065
33296
|
// cacheable-lookup integration hotfix
|
|
@@ -33076,18 +33307,23 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33076
33307
|
let transport;
|
|
33077
33308
|
const isHttpsRequest = isHttps.test(options.protocol);
|
|
33078
33309
|
options.agent = isHttpsRequest ? config.httpsAgent : config.httpAgent;
|
|
33079
|
-
|
|
33080
|
-
|
|
33081
|
-
|
|
33082
|
-
transport = isHttpsRequest ? require$$4$1 : require$$3$1;
|
|
33310
|
+
|
|
33311
|
+
if (isHttp2) {
|
|
33312
|
+
transport = http2Transport;
|
|
33083
33313
|
} else {
|
|
33084
|
-
if (config.
|
|
33085
|
-
|
|
33086
|
-
}
|
|
33087
|
-
|
|
33088
|
-
|
|
33314
|
+
if (config.transport) {
|
|
33315
|
+
transport = config.transport;
|
|
33316
|
+
} else if (config.maxRedirects === 0) {
|
|
33317
|
+
transport = isHttpsRequest ? require$$4$1 : require$$3$1;
|
|
33318
|
+
} else {
|
|
33319
|
+
if (config.maxRedirects) {
|
|
33320
|
+
options.maxRedirects = config.maxRedirects;
|
|
33321
|
+
}
|
|
33322
|
+
if (config.beforeRedirect) {
|
|
33323
|
+
options.beforeRedirects.config = config.beforeRedirect;
|
|
33324
|
+
}
|
|
33325
|
+
transport = isHttpsRequest ? httpsFollow : httpFollow;
|
|
33089
33326
|
}
|
|
33090
|
-
transport = isHttpsRequest ? httpsFollow : httpFollow;
|
|
33091
33327
|
}
|
|
33092
33328
|
|
|
33093
33329
|
if (config.maxBodyLength > -1) {
|
|
@@ -33107,7 +33343,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33107
33343
|
|
|
33108
33344
|
const streams = [res];
|
|
33109
33345
|
|
|
33110
|
-
const responseLength =
|
|
33346
|
+
const responseLength = utils$1.toFiniteNumber(res.headers['content-length']);
|
|
33111
33347
|
|
|
33112
33348
|
if (onDownloadProgress || maxDownloadRate) {
|
|
33113
33349
|
const transformStream = new AxiosTransformStream({
|
|
@@ -33170,15 +33406,12 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33170
33406
|
|
|
33171
33407
|
responseStream = streams.length > 1 ? stream.pipeline(streams, utils$1.noop) : streams[0];
|
|
33172
33408
|
|
|
33173
|
-
|
|
33174
|
-
offListeners();
|
|
33175
|
-
onFinished();
|
|
33176
|
-
});
|
|
33409
|
+
|
|
33177
33410
|
|
|
33178
33411
|
const response = {
|
|
33179
33412
|
status: res.statusCode,
|
|
33180
33413
|
statusText: res.statusMessage,
|
|
33181
|
-
headers: new AxiosHeaders(res.headers),
|
|
33414
|
+
headers: new AxiosHeaders$1(res.headers),
|
|
33182
33415
|
config,
|
|
33183
33416
|
request: lastRequest
|
|
33184
33417
|
};
|
|
@@ -33199,8 +33432,8 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33199
33432
|
// stream.destroy() emit aborted event before calling reject() on Node.js v16
|
|
33200
33433
|
rejected = true;
|
|
33201
33434
|
responseStream.destroy();
|
|
33202
|
-
|
|
33203
|
-
AxiosError.ERR_BAD_RESPONSE, config, lastRequest));
|
|
33435
|
+
abort(new AxiosError$1('maxContentLength size of ' + config.maxContentLength + ' exceeded',
|
|
33436
|
+
AxiosError$1.ERR_BAD_RESPONSE, config, lastRequest));
|
|
33204
33437
|
}
|
|
33205
33438
|
});
|
|
33206
33439
|
|
|
@@ -33209,9 +33442,9 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33209
33442
|
return;
|
|
33210
33443
|
}
|
|
33211
33444
|
|
|
33212
|
-
const err = new AxiosError(
|
|
33445
|
+
const err = new AxiosError$1(
|
|
33213
33446
|
'stream has been aborted',
|
|
33214
|
-
AxiosError.ERR_BAD_RESPONSE,
|
|
33447
|
+
AxiosError$1.ERR_BAD_RESPONSE,
|
|
33215
33448
|
config,
|
|
33216
33449
|
lastRequest
|
|
33217
33450
|
);
|
|
@@ -33221,7 +33454,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33221
33454
|
|
|
33222
33455
|
responseStream.on('error', function handleStreamError(err) {
|
|
33223
33456
|
if (req.destroyed) return;
|
|
33224
|
-
reject(AxiosError.from(err, null, config, lastRequest));
|
|
33457
|
+
reject(AxiosError$1.from(err, null, config, lastRequest));
|
|
33225
33458
|
});
|
|
33226
33459
|
|
|
33227
33460
|
responseStream.on('end', function handleStreamEnd() {
|
|
@@ -33235,13 +33468,13 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33235
33468
|
}
|
|
33236
33469
|
response.data = responseData;
|
|
33237
33470
|
} catch (err) {
|
|
33238
|
-
return reject(AxiosError.from(err, null, config, response.request, response));
|
|
33471
|
+
return reject(AxiosError$1.from(err, null, config, response.request, response));
|
|
33239
33472
|
}
|
|
33240
33473
|
settle(resolve, reject, response);
|
|
33241
33474
|
});
|
|
33242
33475
|
}
|
|
33243
33476
|
|
|
33244
|
-
|
|
33477
|
+
abortEmitter.once('abort', err => {
|
|
33245
33478
|
if (!responseStream.destroyed) {
|
|
33246
33479
|
responseStream.emit('error', err);
|
|
33247
33480
|
responseStream.destroy();
|
|
@@ -33249,16 +33482,17 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33249
33482
|
});
|
|
33250
33483
|
});
|
|
33251
33484
|
|
|
33252
|
-
|
|
33253
|
-
|
|
33254
|
-
|
|
33485
|
+
abortEmitter.once('abort', err => {
|
|
33486
|
+
if (req.close) {
|
|
33487
|
+
req.close();
|
|
33488
|
+
} else {
|
|
33489
|
+
req.destroy(err);
|
|
33490
|
+
}
|
|
33255
33491
|
});
|
|
33256
33492
|
|
|
33257
33493
|
// Handle errors
|
|
33258
33494
|
req.on('error', function handleRequestError(err) {
|
|
33259
|
-
|
|
33260
|
-
// if (req.aborted && err.code !== AxiosError.ERR_FR_TOO_MANY_REDIRECTS) return;
|
|
33261
|
-
reject(AxiosError.from(err, null, config, req));
|
|
33495
|
+
reject(AxiosError$1.from(err, null, config, req));
|
|
33262
33496
|
});
|
|
33263
33497
|
|
|
33264
33498
|
// set tcp keep alive to prevent drop connection by peer
|
|
@@ -33273,9 +33507,9 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33273
33507
|
const timeout = parseInt(config.timeout, 10);
|
|
33274
33508
|
|
|
33275
33509
|
if (Number.isNaN(timeout)) {
|
|
33276
|
-
|
|
33510
|
+
abort(new AxiosError$1(
|
|
33277
33511
|
'error trying to parse `config.timeout` to int',
|
|
33278
|
-
AxiosError.ERR_BAD_OPTION_VALUE,
|
|
33512
|
+
AxiosError$1.ERR_BAD_OPTION_VALUE,
|
|
33279
33513
|
config,
|
|
33280
33514
|
req
|
|
33281
33515
|
));
|
|
@@ -33295,14 +33529,16 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33295
33529
|
if (config.timeoutErrorMessage) {
|
|
33296
33530
|
timeoutErrorMessage = config.timeoutErrorMessage;
|
|
33297
33531
|
}
|
|
33298
|
-
|
|
33532
|
+
abort(new AxiosError$1(
|
|
33299
33533
|
timeoutErrorMessage,
|
|
33300
|
-
transitional.clarifyTimeoutError ? AxiosError.ETIMEDOUT : AxiosError.ECONNABORTED,
|
|
33534
|
+
transitional.clarifyTimeoutError ? AxiosError$1.ETIMEDOUT : AxiosError$1.ECONNABORTED,
|
|
33301
33535
|
config,
|
|
33302
33536
|
req
|
|
33303
33537
|
));
|
|
33304
|
-
abort();
|
|
33305
33538
|
});
|
|
33539
|
+
} else {
|
|
33540
|
+
// explicitly reset the socket timeout value for a possible `keep-alive` request
|
|
33541
|
+
req.setTimeout(0);
|
|
33306
33542
|
}
|
|
33307
33543
|
|
|
33308
33544
|
|
|
@@ -33322,13 +33558,14 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
33322
33558
|
|
|
33323
33559
|
data.on('close', () => {
|
|
33324
33560
|
if (!ended && !errored) {
|
|
33325
|
-
abort(new CanceledError('Request stream has been aborted', config, req));
|
|
33561
|
+
abort(new CanceledError$1('Request stream has been aborted', config, req));
|
|
33326
33562
|
}
|
|
33327
33563
|
});
|
|
33328
33564
|
|
|
33329
33565
|
data.pipe(req);
|
|
33330
33566
|
} else {
|
|
33331
|
-
req.
|
|
33567
|
+
data && req.write(data);
|
|
33568
|
+
req.end();
|
|
33332
33569
|
}
|
|
33333
33570
|
});
|
|
33334
33571
|
};
|
|
@@ -33350,27 +33587,38 @@ var cookies = platform.hasStandardBrowserEnv ?
|
|
|
33350
33587
|
|
|
33351
33588
|
// Standard browser envs support document.cookie
|
|
33352
33589
|
{
|
|
33353
|
-
write(name, value, expires, path, domain, secure) {
|
|
33354
|
-
|
|
33355
|
-
|
|
33356
|
-
utils$1.isNumber(expires) && cookie.push('expires=' + new Date(expires).toGMTString());
|
|
33590
|
+
write(name, value, expires, path, domain, secure, sameSite) {
|
|
33591
|
+
if (typeof document === 'undefined') return;
|
|
33357
33592
|
|
|
33358
|
-
|
|
33593
|
+
const cookie = [`${name}=${encodeURIComponent(value)}`];
|
|
33359
33594
|
|
|
33360
|
-
utils$1.
|
|
33361
|
-
|
|
33362
|
-
|
|
33595
|
+
if (utils$1.isNumber(expires)) {
|
|
33596
|
+
cookie.push(`expires=${new Date(expires).toUTCString()}`);
|
|
33597
|
+
}
|
|
33598
|
+
if (utils$1.isString(path)) {
|
|
33599
|
+
cookie.push(`path=${path}`);
|
|
33600
|
+
}
|
|
33601
|
+
if (utils$1.isString(domain)) {
|
|
33602
|
+
cookie.push(`domain=${domain}`);
|
|
33603
|
+
}
|
|
33604
|
+
if (secure === true) {
|
|
33605
|
+
cookie.push('secure');
|
|
33606
|
+
}
|
|
33607
|
+
if (utils$1.isString(sameSite)) {
|
|
33608
|
+
cookie.push(`SameSite=${sameSite}`);
|
|
33609
|
+
}
|
|
33363
33610
|
|
|
33364
33611
|
document.cookie = cookie.join('; ');
|
|
33365
33612
|
},
|
|
33366
33613
|
|
|
33367
33614
|
read(name) {
|
|
33368
|
-
|
|
33369
|
-
|
|
33615
|
+
if (typeof document === 'undefined') return null;
|
|
33616
|
+
const match = document.cookie.match(new RegExp('(?:^|; )' + name + '=([^;]*)'));
|
|
33617
|
+
return match ? decodeURIComponent(match[1]) : null;
|
|
33370
33618
|
},
|
|
33371
33619
|
|
|
33372
33620
|
remove(name) {
|
|
33373
|
-
this.write(name, '', Date.now() - 86400000);
|
|
33621
|
+
this.write(name, '', Date.now() - 86400000, '/');
|
|
33374
33622
|
}
|
|
33375
33623
|
}
|
|
33376
33624
|
|
|
@@ -33385,7 +33633,8 @@ var cookies = platform.hasStandardBrowserEnv ?
|
|
|
33385
33633
|
remove() {}
|
|
33386
33634
|
};
|
|
33387
33635
|
|
|
33388
|
-
const headersToObject = (thing) =>
|
|
33636
|
+
const headersToObject = (thing) =>
|
|
33637
|
+
thing instanceof AxiosHeaders$1 ? { ...thing } : thing;
|
|
33389
33638
|
|
|
33390
33639
|
/**
|
|
33391
33640
|
* Config-specific merge-function which creates a new config-object
|
|
@@ -33396,14 +33645,14 @@ const headersToObject = (thing) => thing instanceof AxiosHeaders ? { ...thing }
|
|
|
33396
33645
|
*
|
|
33397
33646
|
* @returns {Object} New object resulting from merging config2 to config1
|
|
33398
33647
|
*/
|
|
33399
|
-
function mergeConfig(config1, config2) {
|
|
33648
|
+
function mergeConfig$1(config1, config2) {
|
|
33400
33649
|
// eslint-disable-next-line no-param-reassign
|
|
33401
33650
|
config2 = config2 || {};
|
|
33402
33651
|
const config = {};
|
|
33403
33652
|
|
|
33404
33653
|
function getMergedValue(target, source, prop, caseless) {
|
|
33405
33654
|
if (utils$1.isPlainObject(target) && utils$1.isPlainObject(source)) {
|
|
33406
|
-
return utils$1.merge.call({caseless}, target, source);
|
|
33655
|
+
return utils$1.merge.call({ caseless }, target, source);
|
|
33407
33656
|
} else if (utils$1.isPlainObject(source)) {
|
|
33408
33657
|
return utils$1.merge({}, source);
|
|
33409
33658
|
} else if (utils$1.isArray(source)) {
|
|
@@ -33412,12 +33661,11 @@ function mergeConfig(config1, config2) {
|
|
|
33412
33661
|
return source;
|
|
33413
33662
|
}
|
|
33414
33663
|
|
|
33415
|
-
|
|
33416
|
-
function mergeDeepProperties(a, b, prop , caseless) {
|
|
33664
|
+
function mergeDeepProperties(a, b, prop, caseless) {
|
|
33417
33665
|
if (!utils$1.isUndefined(b)) {
|
|
33418
|
-
return getMergedValue(a, b, prop
|
|
33666
|
+
return getMergedValue(a, b, prop, caseless);
|
|
33419
33667
|
} else if (!utils$1.isUndefined(a)) {
|
|
33420
|
-
return getMergedValue(undefined, a, prop
|
|
33668
|
+
return getMergedValue(undefined, a, prop, caseless);
|
|
33421
33669
|
}
|
|
33422
33670
|
}
|
|
33423
33671
|
|
|
@@ -33475,24 +33723,37 @@ function mergeConfig(config1, config2) {
|
|
|
33475
33723
|
socketPath: defaultToConfig2,
|
|
33476
33724
|
responseEncoding: defaultToConfig2,
|
|
33477
33725
|
validateStatus: mergeDirectKeys,
|
|
33478
|
-
headers: (a, b
|
|
33726
|
+
headers: (a, b, prop) =>
|
|
33727
|
+
mergeDeepProperties(headersToObject(a), headersToObject(b), prop, true),
|
|
33479
33728
|
};
|
|
33480
33729
|
|
|
33481
|
-
utils$1.forEach(
|
|
33482
|
-
|
|
33483
|
-
|
|
33484
|
-
|
|
33485
|
-
|
|
33730
|
+
utils$1.forEach(
|
|
33731
|
+
Object.keys({ ...config1, ...config2 }),
|
|
33732
|
+
function computeConfigValue(prop) {
|
|
33733
|
+
if (
|
|
33734
|
+
prop === "__proto__" ||
|
|
33735
|
+
prop === "constructor" ||
|
|
33736
|
+
prop === "prototype"
|
|
33737
|
+
)
|
|
33738
|
+
return;
|
|
33739
|
+
const merge = utils$1.hasOwnProp(mergeMap, prop)
|
|
33740
|
+
? mergeMap[prop]
|
|
33741
|
+
: mergeDeepProperties;
|
|
33742
|
+
const configValue = merge(config1[prop], config2[prop], prop);
|
|
33743
|
+
(utils$1.isUndefined(configValue) && merge !== mergeDirectKeys) ||
|
|
33744
|
+
(config[prop] = configValue);
|
|
33745
|
+
},
|
|
33746
|
+
);
|
|
33486
33747
|
|
|
33487
33748
|
return config;
|
|
33488
33749
|
}
|
|
33489
33750
|
|
|
33490
33751
|
var resolveConfig = (config) => {
|
|
33491
|
-
const newConfig = mergeConfig({}, config);
|
|
33752
|
+
const newConfig = mergeConfig$1({}, config);
|
|
33492
33753
|
|
|
33493
33754
|
let { data, withXSRFToken, xsrfHeaderName, xsrfCookieName, headers, auth } = newConfig;
|
|
33494
33755
|
|
|
33495
|
-
newConfig.headers = headers = AxiosHeaders.from(headers);
|
|
33756
|
+
newConfig.headers = headers = AxiosHeaders$1.from(headers);
|
|
33496
33757
|
|
|
33497
33758
|
newConfig.url = buildURL(buildFullPath(newConfig.baseURL, newConfig.url, newConfig.allowAbsoluteUrls), config.params, config.paramsSerializer);
|
|
33498
33759
|
|
|
@@ -33545,7 +33806,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
33545
33806
|
return new Promise(function dispatchXhrRequest(resolve, reject) {
|
|
33546
33807
|
const _config = resolveConfig(config);
|
|
33547
33808
|
let requestData = _config.data;
|
|
33548
|
-
const requestHeaders = AxiosHeaders.from(_config.headers).normalize();
|
|
33809
|
+
const requestHeaders = AxiosHeaders$1.from(_config.headers).normalize();
|
|
33549
33810
|
let {responseType, onUploadProgress, onDownloadProgress} = _config;
|
|
33550
33811
|
let onCanceled;
|
|
33551
33812
|
let uploadThrottled, downloadThrottled;
|
|
@@ -33572,7 +33833,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
33572
33833
|
return;
|
|
33573
33834
|
}
|
|
33574
33835
|
// Prepare the response
|
|
33575
|
-
const responseHeaders = AxiosHeaders.from(
|
|
33836
|
+
const responseHeaders = AxiosHeaders$1.from(
|
|
33576
33837
|
'getAllResponseHeaders' in request && request.getAllResponseHeaders()
|
|
33577
33838
|
);
|
|
33578
33839
|
const responseData = !responseType || responseType === 'text' || responseType === 'json' ?
|
|
@@ -33627,7 +33888,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
33627
33888
|
return;
|
|
33628
33889
|
}
|
|
33629
33890
|
|
|
33630
|
-
reject(new AxiosError('Request aborted', AxiosError.ECONNABORTED, config, request));
|
|
33891
|
+
reject(new AxiosError$1('Request aborted', AxiosError$1.ECONNABORTED, config, request));
|
|
33631
33892
|
|
|
33632
33893
|
// Clean up request
|
|
33633
33894
|
request = null;
|
|
@@ -33639,7 +33900,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
33639
33900
|
// (message may be empty; when present, surface it)
|
|
33640
33901
|
// See https://developer.mozilla.org/docs/Web/API/XMLHttpRequest/error_event
|
|
33641
33902
|
const msg = event && event.message ? event.message : 'Network Error';
|
|
33642
|
-
const err = new AxiosError(msg, AxiosError.ERR_NETWORK, config, request);
|
|
33903
|
+
const err = new AxiosError$1(msg, AxiosError$1.ERR_NETWORK, config, request);
|
|
33643
33904
|
// attach the underlying event for consumers who want details
|
|
33644
33905
|
err.event = event || null;
|
|
33645
33906
|
reject(err);
|
|
@@ -33653,9 +33914,9 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
33653
33914
|
if (_config.timeoutErrorMessage) {
|
|
33654
33915
|
timeoutErrorMessage = _config.timeoutErrorMessage;
|
|
33655
33916
|
}
|
|
33656
|
-
reject(new AxiosError(
|
|
33917
|
+
reject(new AxiosError$1(
|
|
33657
33918
|
timeoutErrorMessage,
|
|
33658
|
-
transitional.clarifyTimeoutError ? AxiosError.ETIMEDOUT : AxiosError.ECONNABORTED,
|
|
33919
|
+
transitional.clarifyTimeoutError ? AxiosError$1.ETIMEDOUT : AxiosError$1.ECONNABORTED,
|
|
33659
33920
|
config,
|
|
33660
33921
|
request));
|
|
33661
33922
|
|
|
@@ -33705,7 +33966,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
33705
33966
|
if (!request) {
|
|
33706
33967
|
return;
|
|
33707
33968
|
}
|
|
33708
|
-
reject(!cancel || cancel.type ? new CanceledError(null, config, request) : cancel);
|
|
33969
|
+
reject(!cancel || cancel.type ? new CanceledError$1(null, config, request) : cancel);
|
|
33709
33970
|
request.abort();
|
|
33710
33971
|
request = null;
|
|
33711
33972
|
};
|
|
@@ -33719,7 +33980,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
33719
33980
|
const protocol = parseProtocol(_config.url);
|
|
33720
33981
|
|
|
33721
33982
|
if (protocol && platform.protocols.indexOf(protocol) === -1) {
|
|
33722
|
-
reject(new AxiosError('Unsupported protocol ' + protocol + ':', AxiosError.ERR_BAD_REQUEST, config));
|
|
33983
|
+
reject(new AxiosError$1('Unsupported protocol ' + protocol + ':', AxiosError$1.ERR_BAD_REQUEST, config));
|
|
33723
33984
|
return;
|
|
33724
33985
|
}
|
|
33725
33986
|
|
|
@@ -33742,13 +34003,13 @@ const composeSignals = (signals, timeout) => {
|
|
|
33742
34003
|
aborted = true;
|
|
33743
34004
|
unsubscribe();
|
|
33744
34005
|
const err = reason instanceof Error ? reason : this.reason;
|
|
33745
|
-
controller.abort(err instanceof AxiosError ? err : new CanceledError(err instanceof Error ? err.message : err));
|
|
34006
|
+
controller.abort(err instanceof AxiosError$1 ? err : new CanceledError$1(err instanceof Error ? err.message : err));
|
|
33746
34007
|
}
|
|
33747
34008
|
};
|
|
33748
34009
|
|
|
33749
34010
|
let timer = timeout && setTimeout(() => {
|
|
33750
34011
|
timer = null;
|
|
33751
|
-
onabort(new AxiosError(`timeout ${timeout}
|
|
34012
|
+
onabort(new AxiosError$1(`timeout of ${timeout}ms exceeded`, AxiosError$1.ETIMEDOUT));
|
|
33752
34013
|
}, timeout);
|
|
33753
34014
|
|
|
33754
34015
|
const unsubscribe = () => {
|
|
@@ -33863,9 +34124,9 @@ const DEFAULT_CHUNK_SIZE = 64 * 1024;
|
|
|
33863
34124
|
|
|
33864
34125
|
const {isFunction} = utils$1;
|
|
33865
34126
|
|
|
33866
|
-
const globalFetchAPI = (({
|
|
33867
|
-
|
|
33868
|
-
|
|
34127
|
+
const globalFetchAPI = (({Request, Response}) => ({
|
|
34128
|
+
Request, Response
|
|
34129
|
+
}))(utils$1.global);
|
|
33869
34130
|
|
|
33870
34131
|
const {
|
|
33871
34132
|
ReadableStream: ReadableStream$1, TextEncoder: TextEncoder$1
|
|
@@ -33881,8 +34142,12 @@ const test = (fn, ...args) => {
|
|
|
33881
34142
|
};
|
|
33882
34143
|
|
|
33883
34144
|
const factory = (env) => {
|
|
33884
|
-
|
|
33885
|
-
|
|
34145
|
+
env = utils$1.merge.call({
|
|
34146
|
+
skipUndefined: true
|
|
34147
|
+
}, globalFetchAPI, env);
|
|
34148
|
+
|
|
34149
|
+
const {fetch: envFetch, Request, Response} = env;
|
|
34150
|
+
const isFetchSupported = envFetch ? isFunction(envFetch) : typeof fetch === 'function';
|
|
33886
34151
|
const isRequestSupported = isFunction(Request);
|
|
33887
34152
|
const isResponseSupported = isFunction(Response);
|
|
33888
34153
|
|
|
@@ -33928,7 +34193,7 @@ const factory = (env) => {
|
|
|
33928
34193
|
return method.call(res);
|
|
33929
34194
|
}
|
|
33930
34195
|
|
|
33931
|
-
throw new AxiosError(`Response type '${type}' is not supported`, AxiosError.ERR_NOT_SUPPORT, config);
|
|
34196
|
+
throw new AxiosError$1(`Response type '${type}' is not supported`, AxiosError$1.ERR_NOT_SUPPORT, config);
|
|
33932
34197
|
});
|
|
33933
34198
|
});
|
|
33934
34199
|
})());
|
|
@@ -33985,6 +34250,8 @@ const factory = (env) => {
|
|
|
33985
34250
|
fetchOptions
|
|
33986
34251
|
} = resolveConfig(config);
|
|
33987
34252
|
|
|
34253
|
+
let _fetch = envFetch || fetch;
|
|
34254
|
+
|
|
33988
34255
|
responseType = responseType ? (responseType + '').toLowerCase() : 'text';
|
|
33989
34256
|
|
|
33990
34257
|
let composedSignal = composeSignals([signal, cancelToken && cancelToken.toAbortSignal()], timeout);
|
|
@@ -34044,7 +34311,7 @@ const factory = (env) => {
|
|
|
34044
34311
|
|
|
34045
34312
|
request = isRequestSupported && new Request(url, resolvedOptions);
|
|
34046
34313
|
|
|
34047
|
-
let response = await (isRequestSupported ?
|
|
34314
|
+
let response = await (isRequestSupported ? _fetch(request, fetchOptions) : _fetch(url, resolvedOptions));
|
|
34048
34315
|
|
|
34049
34316
|
const isStreamResponse = supportsResponseStream && (responseType === 'stream' || responseType === 'response');
|
|
34050
34317
|
|
|
@@ -34080,7 +34347,7 @@ const factory = (env) => {
|
|
|
34080
34347
|
return await new Promise((resolve, reject) => {
|
|
34081
34348
|
settle(resolve, reject, {
|
|
34082
34349
|
data: responseData,
|
|
34083
|
-
headers: AxiosHeaders.from(response.headers),
|
|
34350
|
+
headers: AxiosHeaders$1.from(response.headers),
|
|
34084
34351
|
status: response.status,
|
|
34085
34352
|
statusText: response.statusText,
|
|
34086
34353
|
config,
|
|
@@ -34092,14 +34359,14 @@ const factory = (env) => {
|
|
|
34092
34359
|
|
|
34093
34360
|
if (err && err.name === 'TypeError' && /Load failed|fetch/i.test(err.message)) {
|
|
34094
34361
|
throw Object.assign(
|
|
34095
|
-
new AxiosError('Network Error', AxiosError.ERR_NETWORK, config, request),
|
|
34362
|
+
new AxiosError$1('Network Error', AxiosError$1.ERR_NETWORK, config, request, err && err.response),
|
|
34096
34363
|
{
|
|
34097
34364
|
cause: err.cause || err
|
|
34098
34365
|
}
|
|
34099
34366
|
)
|
|
34100
34367
|
}
|
|
34101
34368
|
|
|
34102
|
-
throw AxiosError.from(err, err && err.code, config, request);
|
|
34369
|
+
throw AxiosError$1.from(err, err && err.code, config, request, err && err.response);
|
|
34103
34370
|
}
|
|
34104
34371
|
}
|
|
34105
34372
|
};
|
|
@@ -34107,12 +34374,8 @@ const factory = (env) => {
|
|
|
34107
34374
|
const seedCache = new Map();
|
|
34108
34375
|
|
|
34109
34376
|
const getFetch = (config) => {
|
|
34110
|
-
let env =
|
|
34111
|
-
skipUndefined: true
|
|
34112
|
-
}, globalFetchAPI, config ? config.env : null);
|
|
34113
|
-
|
|
34377
|
+
let env = (config && config.env) || {};
|
|
34114
34378
|
const {fetch, Request, Response} = env;
|
|
34115
|
-
|
|
34116
34379
|
const seeds = [
|
|
34117
34380
|
Request, Response, fetch
|
|
34118
34381
|
];
|
|
@@ -34134,6 +34397,15 @@ const getFetch = (config) => {
|
|
|
34134
34397
|
|
|
34135
34398
|
getFetch();
|
|
34136
34399
|
|
|
34400
|
+
/**
|
|
34401
|
+
* Known adapters mapping.
|
|
34402
|
+
* Provides environment-specific adapters for Axios:
|
|
34403
|
+
* - `http` for Node.js
|
|
34404
|
+
* - `xhr` for browsers
|
|
34405
|
+
* - `fetch` for fetch API-based requests
|
|
34406
|
+
*
|
|
34407
|
+
* @type {Object<string, Function|Object>}
|
|
34408
|
+
*/
|
|
34137
34409
|
const knownAdapters = {
|
|
34138
34410
|
http: httpAdapter,
|
|
34139
34411
|
xhr: xhrAdapter,
|
|
@@ -34142,71 +34414,107 @@ const knownAdapters = {
|
|
|
34142
34414
|
}
|
|
34143
34415
|
};
|
|
34144
34416
|
|
|
34417
|
+
// Assign adapter names for easier debugging and identification
|
|
34145
34418
|
utils$1.forEach(knownAdapters, (fn, value) => {
|
|
34146
34419
|
if (fn) {
|
|
34147
34420
|
try {
|
|
34148
|
-
Object.defineProperty(fn, 'name', {value});
|
|
34421
|
+
Object.defineProperty(fn, 'name', { value });
|
|
34149
34422
|
} catch (e) {
|
|
34150
34423
|
// eslint-disable-next-line no-empty
|
|
34151
34424
|
}
|
|
34152
|
-
Object.defineProperty(fn, 'adapterName', {value});
|
|
34425
|
+
Object.defineProperty(fn, 'adapterName', { value });
|
|
34153
34426
|
}
|
|
34154
34427
|
});
|
|
34155
34428
|
|
|
34429
|
+
/**
|
|
34430
|
+
* Render a rejection reason string for unknown or unsupported adapters
|
|
34431
|
+
*
|
|
34432
|
+
* @param {string} reason
|
|
34433
|
+
* @returns {string}
|
|
34434
|
+
*/
|
|
34156
34435
|
const renderReason = (reason) => `- ${reason}`;
|
|
34157
34436
|
|
|
34437
|
+
/**
|
|
34438
|
+
* Check if the adapter is resolved (function, null, or false)
|
|
34439
|
+
*
|
|
34440
|
+
* @param {Function|null|false} adapter
|
|
34441
|
+
* @returns {boolean}
|
|
34442
|
+
*/
|
|
34158
34443
|
const isResolvedHandle = (adapter) => utils$1.isFunction(adapter) || adapter === null || adapter === false;
|
|
34159
34444
|
|
|
34160
|
-
|
|
34161
|
-
|
|
34162
|
-
|
|
34163
|
-
|
|
34164
|
-
|
|
34165
|
-
|
|
34166
|
-
|
|
34445
|
+
/**
|
|
34446
|
+
* Get the first suitable adapter from the provided list.
|
|
34447
|
+
* Tries each adapter in order until a supported one is found.
|
|
34448
|
+
* Throws an AxiosError if no adapter is suitable.
|
|
34449
|
+
*
|
|
34450
|
+
* @param {Array<string|Function>|string|Function} adapters - Adapter(s) by name or function.
|
|
34451
|
+
* @param {Object} config - Axios request configuration
|
|
34452
|
+
* @throws {AxiosError} If no suitable adapter is available
|
|
34453
|
+
* @returns {Function} The resolved adapter function
|
|
34454
|
+
*/
|
|
34455
|
+
function getAdapter$1(adapters, config) {
|
|
34456
|
+
adapters = utils$1.isArray(adapters) ? adapters : [adapters];
|
|
34167
34457
|
|
|
34168
|
-
|
|
34458
|
+
const { length } = adapters;
|
|
34459
|
+
let nameOrAdapter;
|
|
34460
|
+
let adapter;
|
|
34169
34461
|
|
|
34170
|
-
|
|
34171
|
-
nameOrAdapter = adapters[i];
|
|
34172
|
-
let id;
|
|
34462
|
+
const rejectedReasons = {};
|
|
34173
34463
|
|
|
34174
|
-
|
|
34464
|
+
for (let i = 0; i < length; i++) {
|
|
34465
|
+
nameOrAdapter = adapters[i];
|
|
34466
|
+
let id;
|
|
34175
34467
|
|
|
34176
|
-
|
|
34177
|
-
adapter = knownAdapters[(id = String(nameOrAdapter)).toLowerCase()];
|
|
34468
|
+
adapter = nameOrAdapter;
|
|
34178
34469
|
|
|
34179
|
-
|
|
34180
|
-
|
|
34181
|
-
}
|
|
34182
|
-
}
|
|
34470
|
+
if (!isResolvedHandle(nameOrAdapter)) {
|
|
34471
|
+
adapter = knownAdapters[(id = String(nameOrAdapter)).toLowerCase()];
|
|
34183
34472
|
|
|
34184
|
-
if (adapter
|
|
34185
|
-
|
|
34473
|
+
if (adapter === undefined) {
|
|
34474
|
+
throw new AxiosError$1(`Unknown adapter '${id}'`);
|
|
34186
34475
|
}
|
|
34476
|
+
}
|
|
34187
34477
|
|
|
34188
|
-
|
|
34478
|
+
if (adapter && (utils$1.isFunction(adapter) || (adapter = adapter.get(config)))) {
|
|
34479
|
+
break;
|
|
34189
34480
|
}
|
|
34190
34481
|
|
|
34191
|
-
|
|
34482
|
+
rejectedReasons[id || '#' + i] = adapter;
|
|
34483
|
+
}
|
|
34192
34484
|
|
|
34193
|
-
|
|
34194
|
-
|
|
34195
|
-
|
|
34196
|
-
)
|
|
34485
|
+
if (!adapter) {
|
|
34486
|
+
const reasons = Object.entries(rejectedReasons)
|
|
34487
|
+
.map(([id, state]) => `adapter ${id} ` +
|
|
34488
|
+
(state === false ? 'is not supported by the environment' : 'is not available in the build')
|
|
34489
|
+
);
|
|
34197
34490
|
|
|
34198
|
-
|
|
34199
|
-
|
|
34200
|
-
|
|
34491
|
+
let s = length ?
|
|
34492
|
+
(reasons.length > 1 ? 'since :\n' + reasons.map(renderReason).join('\n') : ' ' + renderReason(reasons[0])) :
|
|
34493
|
+
'as no adapter specified';
|
|
34201
34494
|
|
|
34202
|
-
|
|
34203
|
-
|
|
34204
|
-
|
|
34205
|
-
|
|
34206
|
-
|
|
34495
|
+
throw new AxiosError$1(
|
|
34496
|
+
`There is no suitable adapter to dispatch the request ` + s,
|
|
34497
|
+
'ERR_NOT_SUPPORT'
|
|
34498
|
+
);
|
|
34499
|
+
}
|
|
34207
34500
|
|
|
34208
|
-
|
|
34209
|
-
|
|
34501
|
+
return adapter;
|
|
34502
|
+
}
|
|
34503
|
+
|
|
34504
|
+
/**
|
|
34505
|
+
* Exports Axios adapters and utility to resolve an adapter
|
|
34506
|
+
*/
|
|
34507
|
+
var adapters = {
|
|
34508
|
+
/**
|
|
34509
|
+
* Resolve an adapter from a list of adapter names or functions.
|
|
34510
|
+
* @type {Function}
|
|
34511
|
+
*/
|
|
34512
|
+
getAdapter: getAdapter$1,
|
|
34513
|
+
|
|
34514
|
+
/**
|
|
34515
|
+
* Exposes all known adapters
|
|
34516
|
+
* @type {Object<string, Function|Object>}
|
|
34517
|
+
*/
|
|
34210
34518
|
adapters: knownAdapters
|
|
34211
34519
|
};
|
|
34212
34520
|
|
|
@@ -34223,7 +34531,7 @@ function throwIfCancellationRequested(config) {
|
|
|
34223
34531
|
}
|
|
34224
34532
|
|
|
34225
34533
|
if (config.signal && config.signal.aborted) {
|
|
34226
|
-
throw new CanceledError(null, config);
|
|
34534
|
+
throw new CanceledError$1(null, config);
|
|
34227
34535
|
}
|
|
34228
34536
|
}
|
|
34229
34537
|
|
|
@@ -34237,7 +34545,7 @@ function throwIfCancellationRequested(config) {
|
|
|
34237
34545
|
function dispatchRequest(config) {
|
|
34238
34546
|
throwIfCancellationRequested(config);
|
|
34239
34547
|
|
|
34240
|
-
config.headers = AxiosHeaders.from(config.headers);
|
|
34548
|
+
config.headers = AxiosHeaders$1.from(config.headers);
|
|
34241
34549
|
|
|
34242
34550
|
// Transform request data
|
|
34243
34551
|
config.data = transformData.call(
|
|
@@ -34261,11 +34569,11 @@ function dispatchRequest(config) {
|
|
|
34261
34569
|
response
|
|
34262
34570
|
);
|
|
34263
34571
|
|
|
34264
|
-
response.headers = AxiosHeaders.from(response.headers);
|
|
34572
|
+
response.headers = AxiosHeaders$1.from(response.headers);
|
|
34265
34573
|
|
|
34266
34574
|
return response;
|
|
34267
34575
|
}, function onAdapterRejection(reason) {
|
|
34268
|
-
if (!isCancel(reason)) {
|
|
34576
|
+
if (!isCancel$1(reason)) {
|
|
34269
34577
|
throwIfCancellationRequested(config);
|
|
34270
34578
|
|
|
34271
34579
|
// Transform response data
|
|
@@ -34275,7 +34583,7 @@ function dispatchRequest(config) {
|
|
|
34275
34583
|
config.transformResponse,
|
|
34276
34584
|
reason.response
|
|
34277
34585
|
);
|
|
34278
|
-
reason.response.headers = AxiosHeaders.from(reason.response.headers);
|
|
34586
|
+
reason.response.headers = AxiosHeaders$1.from(reason.response.headers);
|
|
34279
34587
|
}
|
|
34280
34588
|
}
|
|
34281
34589
|
|
|
@@ -34305,15 +34613,15 @@ const deprecatedWarnings = {};
|
|
|
34305
34613
|
*/
|
|
34306
34614
|
validators$1.transitional = function transitional(validator, version, message) {
|
|
34307
34615
|
function formatMessage(opt, desc) {
|
|
34308
|
-
return '[Axios v' + VERSION + '] Transitional option \'' + opt + '\'' + desc + (message ? '. ' + message : '');
|
|
34616
|
+
return '[Axios v' + VERSION$1 + '] Transitional option \'' + opt + '\'' + desc + (message ? '. ' + message : '');
|
|
34309
34617
|
}
|
|
34310
34618
|
|
|
34311
34619
|
// eslint-disable-next-line func-names
|
|
34312
34620
|
return (value, opt, opts) => {
|
|
34313
34621
|
if (validator === false) {
|
|
34314
|
-
throw new AxiosError(
|
|
34622
|
+
throw new AxiosError$1(
|
|
34315
34623
|
formatMessage(opt, ' has been removed' + (version ? ' in ' + version : '')),
|
|
34316
|
-
AxiosError.ERR_DEPRECATED
|
|
34624
|
+
AxiosError$1.ERR_DEPRECATED
|
|
34317
34625
|
);
|
|
34318
34626
|
}
|
|
34319
34627
|
|
|
@@ -34352,7 +34660,7 @@ validators$1.spelling = function spelling(correctSpelling) {
|
|
|
34352
34660
|
|
|
34353
34661
|
function assertOptions(options, schema, allowUnknown) {
|
|
34354
34662
|
if (typeof options !== 'object') {
|
|
34355
|
-
throw new AxiosError('options must be an object', AxiosError.ERR_BAD_OPTION_VALUE);
|
|
34663
|
+
throw new AxiosError$1('options must be an object', AxiosError$1.ERR_BAD_OPTION_VALUE);
|
|
34356
34664
|
}
|
|
34357
34665
|
const keys = Object.keys(options);
|
|
34358
34666
|
let i = keys.length;
|
|
@@ -34363,12 +34671,12 @@ function assertOptions(options, schema, allowUnknown) {
|
|
|
34363
34671
|
const value = options[opt];
|
|
34364
34672
|
const result = value === undefined || validator(value, opt, options);
|
|
34365
34673
|
if (result !== true) {
|
|
34366
|
-
throw new AxiosError('option ' + opt + ' must be ' + result, AxiosError.ERR_BAD_OPTION_VALUE);
|
|
34674
|
+
throw new AxiosError$1('option ' + opt + ' must be ' + result, AxiosError$1.ERR_BAD_OPTION_VALUE);
|
|
34367
34675
|
}
|
|
34368
34676
|
continue;
|
|
34369
34677
|
}
|
|
34370
34678
|
if (allowUnknown !== true) {
|
|
34371
|
-
throw new AxiosError('Unknown option ' + opt, AxiosError.ERR_BAD_OPTION);
|
|
34679
|
+
throw new AxiosError$1('Unknown option ' + opt, AxiosError$1.ERR_BAD_OPTION);
|
|
34372
34680
|
}
|
|
34373
34681
|
}
|
|
34374
34682
|
}
|
|
@@ -34387,7 +34695,7 @@ const validators = validator.validators;
|
|
|
34387
34695
|
*
|
|
34388
34696
|
* @return {Axios} A new instance of Axios
|
|
34389
34697
|
*/
|
|
34390
|
-
class Axios {
|
|
34698
|
+
let Axios$1 = class Axios {
|
|
34391
34699
|
constructor(instanceConfig) {
|
|
34392
34700
|
this.defaults = instanceConfig || {};
|
|
34393
34701
|
this.interceptors = {
|
|
@@ -34441,7 +34749,7 @@ class Axios {
|
|
|
34441
34749
|
config = configOrUrl || {};
|
|
34442
34750
|
}
|
|
34443
34751
|
|
|
34444
|
-
config = mergeConfig(this.defaults, config);
|
|
34752
|
+
config = mergeConfig$1(this.defaults, config);
|
|
34445
34753
|
|
|
34446
34754
|
const {transitional, paramsSerializer, headers} = config;
|
|
34447
34755
|
|
|
@@ -34449,7 +34757,8 @@ class Axios {
|
|
|
34449
34757
|
validator.assertOptions(transitional, {
|
|
34450
34758
|
silentJSONParsing: validators.transitional(validators.boolean),
|
|
34451
34759
|
forcedJSONParsing: validators.transitional(validators.boolean),
|
|
34452
|
-
clarifyTimeoutError: validators.transitional(validators.boolean)
|
|
34760
|
+
clarifyTimeoutError: validators.transitional(validators.boolean),
|
|
34761
|
+
legacyInterceptorReqResOrdering: validators.transitional(validators.boolean)
|
|
34453
34762
|
}, false);
|
|
34454
34763
|
}
|
|
34455
34764
|
|
|
@@ -34494,7 +34803,7 @@ class Axios {
|
|
|
34494
34803
|
}
|
|
34495
34804
|
);
|
|
34496
34805
|
|
|
34497
|
-
config.headers = AxiosHeaders.concat(contextHeaders, headers);
|
|
34806
|
+
config.headers = AxiosHeaders$1.concat(contextHeaders, headers);
|
|
34498
34807
|
|
|
34499
34808
|
// filter out skipped interceptors
|
|
34500
34809
|
const requestInterceptorChain = [];
|
|
@@ -34506,7 +34815,14 @@ class Axios {
|
|
|
34506
34815
|
|
|
34507
34816
|
synchronousRequestInterceptors = synchronousRequestInterceptors && interceptor.synchronous;
|
|
34508
34817
|
|
|
34509
|
-
|
|
34818
|
+
const transitional = config.transitional || transitionalDefaults;
|
|
34819
|
+
const legacyInterceptorReqResOrdering = transitional && transitional.legacyInterceptorReqResOrdering;
|
|
34820
|
+
|
|
34821
|
+
if (legacyInterceptorReqResOrdering) {
|
|
34822
|
+
requestInterceptorChain.unshift(interceptor.fulfilled, interceptor.rejected);
|
|
34823
|
+
} else {
|
|
34824
|
+
requestInterceptorChain.push(interceptor.fulfilled, interceptor.rejected);
|
|
34825
|
+
}
|
|
34510
34826
|
});
|
|
34511
34827
|
|
|
34512
34828
|
const responseInterceptorChain = [];
|
|
@@ -34537,8 +34853,6 @@ class Axios {
|
|
|
34537
34853
|
|
|
34538
34854
|
let newConfig = config;
|
|
34539
34855
|
|
|
34540
|
-
i = 0;
|
|
34541
|
-
|
|
34542
34856
|
while (i < len) {
|
|
34543
34857
|
const onFulfilled = requestInterceptorChain[i++];
|
|
34544
34858
|
const onRejected = requestInterceptorChain[i++];
|
|
@@ -34567,17 +34881,17 @@ class Axios {
|
|
|
34567
34881
|
}
|
|
34568
34882
|
|
|
34569
34883
|
getUri(config) {
|
|
34570
|
-
config = mergeConfig(this.defaults, config);
|
|
34884
|
+
config = mergeConfig$1(this.defaults, config);
|
|
34571
34885
|
const fullPath = buildFullPath(config.baseURL, config.url, config.allowAbsoluteUrls);
|
|
34572
34886
|
return buildURL(fullPath, config.params, config.paramsSerializer);
|
|
34573
34887
|
}
|
|
34574
|
-
}
|
|
34888
|
+
};
|
|
34575
34889
|
|
|
34576
34890
|
// Provide aliases for supported request methods
|
|
34577
34891
|
utils$1.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {
|
|
34578
34892
|
/*eslint func-names:0*/
|
|
34579
|
-
Axios.prototype[method] = function(url, config) {
|
|
34580
|
-
return this.request(mergeConfig(config || {}, {
|
|
34893
|
+
Axios$1.prototype[method] = function(url, config) {
|
|
34894
|
+
return this.request(mergeConfig$1(config || {}, {
|
|
34581
34895
|
method,
|
|
34582
34896
|
url,
|
|
34583
34897
|
data: (config || {}).data
|
|
@@ -34590,7 +34904,7 @@ utils$1.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method)
|
|
|
34590
34904
|
|
|
34591
34905
|
function generateHTTPMethod(isForm) {
|
|
34592
34906
|
return function httpMethod(url, data, config) {
|
|
34593
|
-
return this.request(mergeConfig(config || {}, {
|
|
34907
|
+
return this.request(mergeConfig$1(config || {}, {
|
|
34594
34908
|
method,
|
|
34595
34909
|
headers: isForm ? {
|
|
34596
34910
|
'Content-Type': 'multipart/form-data'
|
|
@@ -34601,9 +34915,9 @@ utils$1.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method)
|
|
|
34601
34915
|
};
|
|
34602
34916
|
}
|
|
34603
34917
|
|
|
34604
|
-
Axios.prototype[method] = generateHTTPMethod();
|
|
34918
|
+
Axios$1.prototype[method] = generateHTTPMethod();
|
|
34605
34919
|
|
|
34606
|
-
Axios.prototype[method + 'Form'] = generateHTTPMethod(true);
|
|
34920
|
+
Axios$1.prototype[method + 'Form'] = generateHTTPMethod(true);
|
|
34607
34921
|
});
|
|
34608
34922
|
|
|
34609
34923
|
/**
|
|
@@ -34613,7 +34927,7 @@ utils$1.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method)
|
|
|
34613
34927
|
*
|
|
34614
34928
|
* @returns {CancelToken}
|
|
34615
34929
|
*/
|
|
34616
|
-
class CancelToken {
|
|
34930
|
+
let CancelToken$1 = class CancelToken {
|
|
34617
34931
|
constructor(executor) {
|
|
34618
34932
|
if (typeof executor !== 'function') {
|
|
34619
34933
|
throw new TypeError('executor must be a function.');
|
|
@@ -34661,7 +34975,7 @@ class CancelToken {
|
|
|
34661
34975
|
return;
|
|
34662
34976
|
}
|
|
34663
34977
|
|
|
34664
|
-
token.reason = new CanceledError(message, config, request);
|
|
34978
|
+
token.reason = new CanceledError$1(message, config, request);
|
|
34665
34979
|
resolvePromise(token.reason);
|
|
34666
34980
|
});
|
|
34667
34981
|
}
|
|
@@ -34734,7 +35048,7 @@ class CancelToken {
|
|
|
34734
35048
|
cancel
|
|
34735
35049
|
};
|
|
34736
35050
|
}
|
|
34737
|
-
}
|
|
35051
|
+
};
|
|
34738
35052
|
|
|
34739
35053
|
/**
|
|
34740
35054
|
* Syntactic sugar for invoking a function and expanding an array for arguments.
|
|
@@ -34743,7 +35057,7 @@ class CancelToken {
|
|
|
34743
35057
|
*
|
|
34744
35058
|
* ```js
|
|
34745
35059
|
* function f(x, y, z) {}
|
|
34746
|
-
*
|
|
35060
|
+
* const args = [1, 2, 3];
|
|
34747
35061
|
* f.apply(null, args);
|
|
34748
35062
|
* ```
|
|
34749
35063
|
*
|
|
@@ -34757,7 +35071,7 @@ class CancelToken {
|
|
|
34757
35071
|
*
|
|
34758
35072
|
* @returns {Function}
|
|
34759
35073
|
*/
|
|
34760
|
-
function spread(callback) {
|
|
35074
|
+
function spread$1(callback) {
|
|
34761
35075
|
return function wrap(arr) {
|
|
34762
35076
|
return callback.apply(null, arr);
|
|
34763
35077
|
};
|
|
@@ -34770,11 +35084,11 @@ function spread(callback) {
|
|
|
34770
35084
|
*
|
|
34771
35085
|
* @returns {boolean} True if the payload is an error thrown by Axios, otherwise false
|
|
34772
35086
|
*/
|
|
34773
|
-
function isAxiosError(payload) {
|
|
35087
|
+
function isAxiosError$1(payload) {
|
|
34774
35088
|
return utils$1.isObject(payload) && (payload.isAxiosError === true);
|
|
34775
35089
|
}
|
|
34776
35090
|
|
|
34777
|
-
const HttpStatusCode = {
|
|
35091
|
+
const HttpStatusCode$1 = {
|
|
34778
35092
|
Continue: 100,
|
|
34779
35093
|
SwitchingProtocols: 101,
|
|
34780
35094
|
Processing: 102,
|
|
@@ -34838,10 +35152,16 @@ const HttpStatusCode = {
|
|
|
34838
35152
|
LoopDetected: 508,
|
|
34839
35153
|
NotExtended: 510,
|
|
34840
35154
|
NetworkAuthenticationRequired: 511,
|
|
35155
|
+
WebServerIsDown: 521,
|
|
35156
|
+
ConnectionTimedOut: 522,
|
|
35157
|
+
OriginIsUnreachable: 523,
|
|
35158
|
+
TimeoutOccurred: 524,
|
|
35159
|
+
SslHandshakeFailed: 525,
|
|
35160
|
+
InvalidSslCertificate: 526,
|
|
34841
35161
|
};
|
|
34842
35162
|
|
|
34843
|
-
Object.entries(HttpStatusCode).forEach(([key, value]) => {
|
|
34844
|
-
HttpStatusCode[value] = key;
|
|
35163
|
+
Object.entries(HttpStatusCode$1).forEach(([key, value]) => {
|
|
35164
|
+
HttpStatusCode$1[value] = key;
|
|
34845
35165
|
});
|
|
34846
35166
|
|
|
34847
35167
|
/**
|
|
@@ -34852,18 +35172,18 @@ Object.entries(HttpStatusCode).forEach(([key, value]) => {
|
|
|
34852
35172
|
* @returns {Axios} A new instance of Axios
|
|
34853
35173
|
*/
|
|
34854
35174
|
function createInstance(defaultConfig) {
|
|
34855
|
-
const context = new Axios(defaultConfig);
|
|
34856
|
-
const instance = bind$2(Axios.prototype.request, context);
|
|
35175
|
+
const context = new Axios$1(defaultConfig);
|
|
35176
|
+
const instance = bind$2(Axios$1.prototype.request, context);
|
|
34857
35177
|
|
|
34858
35178
|
// Copy axios.prototype to instance
|
|
34859
|
-
utils$1.extend(instance, Axios.prototype, context, {allOwnKeys: true});
|
|
35179
|
+
utils$1.extend(instance, Axios$1.prototype, context, {allOwnKeys: true});
|
|
34860
35180
|
|
|
34861
35181
|
// Copy context to instance
|
|
34862
35182
|
utils$1.extend(instance, context, null, {allOwnKeys: true});
|
|
34863
35183
|
|
|
34864
35184
|
// Factory for creating new instances
|
|
34865
35185
|
instance.create = function create(instanceConfig) {
|
|
34866
|
-
return createInstance(mergeConfig(defaultConfig, instanceConfig));
|
|
35186
|
+
return createInstance(mergeConfig$1(defaultConfig, instanceConfig));
|
|
34867
35187
|
};
|
|
34868
35188
|
|
|
34869
35189
|
return instance;
|
|
@@ -34873,17 +35193,17 @@ function createInstance(defaultConfig) {
|
|
|
34873
35193
|
const axios = createInstance(defaults);
|
|
34874
35194
|
|
|
34875
35195
|
// Expose Axios class to allow class inheritance
|
|
34876
|
-
axios.Axios = Axios;
|
|
35196
|
+
axios.Axios = Axios$1;
|
|
34877
35197
|
|
|
34878
35198
|
// Expose Cancel & CancelToken
|
|
34879
|
-
axios.CanceledError = CanceledError;
|
|
34880
|
-
axios.CancelToken = CancelToken;
|
|
34881
|
-
axios.isCancel = isCancel;
|
|
34882
|
-
axios.VERSION = VERSION;
|
|
34883
|
-
axios.toFormData = toFormData;
|
|
35199
|
+
axios.CanceledError = CanceledError$1;
|
|
35200
|
+
axios.CancelToken = CancelToken$1;
|
|
35201
|
+
axios.isCancel = isCancel$1;
|
|
35202
|
+
axios.VERSION = VERSION$1;
|
|
35203
|
+
axios.toFormData = toFormData$1;
|
|
34884
35204
|
|
|
34885
35205
|
// Expose AxiosError class
|
|
34886
|
-
axios.AxiosError = AxiosError;
|
|
35206
|
+
axios.AxiosError = AxiosError$1;
|
|
34887
35207
|
|
|
34888
35208
|
// alias for CanceledError for backward compatibility
|
|
34889
35209
|
axios.Cancel = axios.CanceledError;
|
|
@@ -34893,24 +35213,46 @@ axios.all = function all(promises) {
|
|
|
34893
35213
|
return Promise.all(promises);
|
|
34894
35214
|
};
|
|
34895
35215
|
|
|
34896
|
-
axios.spread = spread;
|
|
35216
|
+
axios.spread = spread$1;
|
|
34897
35217
|
|
|
34898
35218
|
// Expose isAxiosError
|
|
34899
|
-
axios.isAxiosError = isAxiosError;
|
|
35219
|
+
axios.isAxiosError = isAxiosError$1;
|
|
34900
35220
|
|
|
34901
35221
|
// Expose mergeConfig
|
|
34902
|
-
axios.mergeConfig = mergeConfig;
|
|
35222
|
+
axios.mergeConfig = mergeConfig$1;
|
|
34903
35223
|
|
|
34904
|
-
axios.AxiosHeaders = AxiosHeaders;
|
|
35224
|
+
axios.AxiosHeaders = AxiosHeaders$1;
|
|
34905
35225
|
|
|
34906
35226
|
axios.formToJSON = thing => formDataToJSON(utils$1.isHTMLForm(thing) ? new FormData(thing) : thing);
|
|
34907
35227
|
|
|
34908
35228
|
axios.getAdapter = adapters.getAdapter;
|
|
34909
35229
|
|
|
34910
|
-
axios.HttpStatusCode = HttpStatusCode;
|
|
35230
|
+
axios.HttpStatusCode = HttpStatusCode$1;
|
|
34911
35231
|
|
|
34912
35232
|
axios.default = axios;
|
|
34913
35233
|
|
|
35234
|
+
// This module is intended to unwrap Axios default export as named.
|
|
35235
|
+
// Keep top-level export same with static properties
|
|
35236
|
+
// so that it can keep same with es module or cjs
|
|
35237
|
+
const {
|
|
35238
|
+
Axios,
|
|
35239
|
+
AxiosError,
|
|
35240
|
+
CanceledError,
|
|
35241
|
+
isCancel,
|
|
35242
|
+
CancelToken,
|
|
35243
|
+
VERSION,
|
|
35244
|
+
all,
|
|
35245
|
+
Cancel,
|
|
35246
|
+
isAxiosError,
|
|
35247
|
+
spread,
|
|
35248
|
+
toFormData,
|
|
35249
|
+
AxiosHeaders,
|
|
35250
|
+
HttpStatusCode,
|
|
35251
|
+
formToJSON,
|
|
35252
|
+
getAdapter,
|
|
35253
|
+
mergeConfig
|
|
35254
|
+
} = axios;
|
|
35255
|
+
|
|
34914
35256
|
path$2.resolve("./package.json");
|
|
34915
35257
|
|
|
34916
35258
|
const DEPENDENCY_TYPES = {
|