axios 1.6.6 → 1.6.8
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.
Potentially problematic release.
This version of axios might be problematic. Click here for more details.
- package/CHANGELOG.md +31 -0
- package/README.md +5 -2
- package/dist/axios.js +322 -299
- package/dist/axios.js.map +1 -1
- package/dist/axios.min.js +1 -1
- package/dist/axios.min.js.map +1 -1
- package/dist/browser/axios.cjs +17 -17
- package/dist/browser/axios.cjs.map +1 -1
- package/dist/esm/axios.js +17 -17
- package/dist/esm/axios.js.map +1 -1
- package/dist/esm/axios.min.js +1 -1
- package/dist/esm/axios.min.js.map +1 -1
- package/dist/node/axios.cjs +19 -20
- package/dist/node/axios.cjs.map +1 -1
- package/lib/adapters/http.js +1 -1
- package/lib/core/Axios.js +14 -11
- package/lib/core/mergeConfig.js +1 -1
- package/lib/defaults/index.js +0 -3
- package/lib/env/data.js +1 -1
- package/package.json +25 -25
package/dist/axios.js
CHANGED
@@ -1,330 +1,381 @@
|
|
1
|
-
// Axios v1.6.
|
1
|
+
// Axios v1.6.8 Copyright (c) 2024 Matt Zabriskie and contributors
|
2
2
|
(function (global, factory) {
|
3
3
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
4
4
|
typeof define === 'function' && define.amd ? define(factory) :
|
5
5
|
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.axios = factory());
|
6
6
|
})(this, (function () { 'use strict';
|
7
7
|
|
8
|
-
function
|
9
|
-
var
|
8
|
+
function _iterableToArrayLimit(r, l) {
|
9
|
+
var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
10
|
+
if (null != t) {
|
11
|
+
var e,
|
12
|
+
n,
|
13
|
+
i,
|
14
|
+
u,
|
15
|
+
a = [],
|
16
|
+
f = !0,
|
17
|
+
o = !1;
|
18
|
+
try {
|
19
|
+
if (i = (t = t.call(r)).next, 0 === l) {
|
20
|
+
if (Object(t) !== t) return;
|
21
|
+
f = !1;
|
22
|
+
} else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
|
23
|
+
} catch (r) {
|
24
|
+
o = !0, n = r;
|
25
|
+
} finally {
|
26
|
+
try {
|
27
|
+
if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
|
28
|
+
} finally {
|
29
|
+
if (o) throw n;
|
30
|
+
}
|
31
|
+
}
|
32
|
+
return a;
|
33
|
+
}
|
34
|
+
}
|
35
|
+
function ownKeys(e, r) {
|
36
|
+
var t = Object.keys(e);
|
10
37
|
if (Object.getOwnPropertySymbols) {
|
11
|
-
var
|
12
|
-
|
13
|
-
return Object.getOwnPropertyDescriptor(
|
14
|
-
})),
|
15
|
-
}
|
16
|
-
return
|
17
|
-
}
|
18
|
-
function _objectSpread2(
|
19
|
-
for (var
|
20
|
-
var
|
21
|
-
|
22
|
-
_defineProperty(
|
23
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(
|
24
|
-
Object.defineProperty(
|
38
|
+
var o = Object.getOwnPropertySymbols(e);
|
39
|
+
r && (o = o.filter(function (r) {
|
40
|
+
return Object.getOwnPropertyDescriptor(e, r).enumerable;
|
41
|
+
})), t.push.apply(t, o);
|
42
|
+
}
|
43
|
+
return t;
|
44
|
+
}
|
45
|
+
function _objectSpread2(e) {
|
46
|
+
for (var r = 1; r < arguments.length; r++) {
|
47
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
48
|
+
r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {
|
49
|
+
_defineProperty(e, r, t[r]);
|
50
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {
|
51
|
+
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
|
25
52
|
});
|
26
53
|
}
|
27
|
-
return
|
54
|
+
return e;
|
28
55
|
}
|
29
56
|
function _regeneratorRuntime() {
|
30
57
|
_regeneratorRuntime = function () {
|
31
|
-
return
|
58
|
+
return e;
|
32
59
|
};
|
33
|
-
var
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
60
|
+
var t,
|
61
|
+
e = {},
|
62
|
+
r = Object.prototype,
|
63
|
+
n = r.hasOwnProperty,
|
64
|
+
o = Object.defineProperty || function (t, e, r) {
|
65
|
+
t[e] = r.value;
|
66
|
+
},
|
67
|
+
i = "function" == typeof Symbol ? Symbol : {},
|
68
|
+
a = i.iterator || "@@iterator",
|
69
|
+
c = i.asyncIterator || "@@asyncIterator",
|
70
|
+
u = i.toStringTag || "@@toStringTag";
|
71
|
+
function define(t, e, r) {
|
72
|
+
return Object.defineProperty(t, e, {
|
73
|
+
value: r,
|
43
74
|
enumerable: !0,
|
44
75
|
configurable: !0,
|
45
76
|
writable: !0
|
46
|
-
}),
|
77
|
+
}), t[e];
|
47
78
|
}
|
48
79
|
try {
|
49
80
|
define({}, "");
|
50
|
-
} catch (
|
51
|
-
define = function (
|
52
|
-
return
|
81
|
+
} catch (t) {
|
82
|
+
define = function (t, e, r) {
|
83
|
+
return t[e] = r;
|
53
84
|
};
|
54
85
|
}
|
55
|
-
function wrap(
|
56
|
-
var
|
57
|
-
|
58
|
-
|
59
|
-
return
|
60
|
-
|
61
|
-
|
62
|
-
if ("executing" === state) throw new Error("Generator is already running");
|
63
|
-
if ("completed" === state) {
|
64
|
-
if ("throw" === method) throw arg;
|
65
|
-
return doneResult();
|
66
|
-
}
|
67
|
-
for (context.method = method, context.arg = arg;;) {
|
68
|
-
var delegate = context.delegate;
|
69
|
-
if (delegate) {
|
70
|
-
var delegateResult = maybeInvokeDelegate(delegate, context);
|
71
|
-
if (delegateResult) {
|
72
|
-
if (delegateResult === ContinueSentinel) continue;
|
73
|
-
return delegateResult;
|
74
|
-
}
|
75
|
-
}
|
76
|
-
if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) {
|
77
|
-
if ("suspendedStart" === state) throw state = "completed", context.arg;
|
78
|
-
context.dispatchException(context.arg);
|
79
|
-
} else "return" === context.method && context.abrupt("return", context.arg);
|
80
|
-
state = "executing";
|
81
|
-
var record = tryCatch(innerFn, self, context);
|
82
|
-
if ("normal" === record.type) {
|
83
|
-
if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue;
|
84
|
-
return {
|
85
|
-
value: record.arg,
|
86
|
-
done: context.done
|
87
|
-
};
|
88
|
-
}
|
89
|
-
"throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg);
|
90
|
-
}
|
91
|
-
};
|
92
|
-
}(innerFn, self, context), generator;
|
86
|
+
function wrap(t, e, r, n) {
|
87
|
+
var i = e && e.prototype instanceof Generator ? e : Generator,
|
88
|
+
a = Object.create(i.prototype),
|
89
|
+
c = new Context(n || []);
|
90
|
+
return o(a, "_invoke", {
|
91
|
+
value: makeInvokeMethod(t, r, c)
|
92
|
+
}), a;
|
93
93
|
}
|
94
|
-
function tryCatch(
|
94
|
+
function tryCatch(t, e, r) {
|
95
95
|
try {
|
96
96
|
return {
|
97
97
|
type: "normal",
|
98
|
-
arg:
|
98
|
+
arg: t.call(e, r)
|
99
99
|
};
|
100
|
-
} catch (
|
100
|
+
} catch (t) {
|
101
101
|
return {
|
102
102
|
type: "throw",
|
103
|
-
arg:
|
103
|
+
arg: t
|
104
104
|
};
|
105
105
|
}
|
106
106
|
}
|
107
|
-
|
108
|
-
var
|
107
|
+
e.wrap = wrap;
|
108
|
+
var h = "suspendedStart",
|
109
|
+
l = "suspendedYield",
|
110
|
+
f = "executing",
|
111
|
+
s = "completed",
|
112
|
+
y = {};
|
109
113
|
function Generator() {}
|
110
114
|
function GeneratorFunction() {}
|
111
115
|
function GeneratorFunctionPrototype() {}
|
112
|
-
var
|
113
|
-
define(
|
116
|
+
var p = {};
|
117
|
+
define(p, a, function () {
|
114
118
|
return this;
|
115
119
|
});
|
116
|
-
var
|
117
|
-
|
118
|
-
|
119
|
-
var
|
120
|
-
function defineIteratorMethods(
|
121
|
-
["next", "throw", "return"].forEach(function (
|
122
|
-
define(
|
123
|
-
return this._invoke(
|
120
|
+
var d = Object.getPrototypeOf,
|
121
|
+
v = d && d(d(values([])));
|
122
|
+
v && v !== r && n.call(v, a) && (p = v);
|
123
|
+
var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p);
|
124
|
+
function defineIteratorMethods(t) {
|
125
|
+
["next", "throw", "return"].forEach(function (e) {
|
126
|
+
define(t, e, function (t) {
|
127
|
+
return this._invoke(e, t);
|
124
128
|
});
|
125
129
|
});
|
126
130
|
}
|
127
|
-
function AsyncIterator(
|
128
|
-
function invoke(
|
129
|
-
var
|
130
|
-
if ("throw" !==
|
131
|
-
var
|
132
|
-
|
133
|
-
return
|
134
|
-
invoke("next",
|
135
|
-
}, function (
|
136
|
-
invoke("throw",
|
137
|
-
}) :
|
138
|
-
|
139
|
-
}, function (
|
140
|
-
return invoke("throw",
|
131
|
+
function AsyncIterator(t, e) {
|
132
|
+
function invoke(r, o, i, a) {
|
133
|
+
var c = tryCatch(t[r], t, o);
|
134
|
+
if ("throw" !== c.type) {
|
135
|
+
var u = c.arg,
|
136
|
+
h = u.value;
|
137
|
+
return h && "object" == typeof h && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) {
|
138
|
+
invoke("next", t, i, a);
|
139
|
+
}, function (t) {
|
140
|
+
invoke("throw", t, i, a);
|
141
|
+
}) : e.resolve(h).then(function (t) {
|
142
|
+
u.value = t, i(u);
|
143
|
+
}, function (t) {
|
144
|
+
return invoke("throw", t, i, a);
|
141
145
|
});
|
142
146
|
}
|
143
|
-
|
147
|
+
a(c.arg);
|
144
148
|
}
|
145
|
-
var
|
146
|
-
this
|
147
|
-
function
|
148
|
-
|
149
|
-
|
150
|
-
|
149
|
+
var r;
|
150
|
+
o(this, "_invoke", {
|
151
|
+
value: function (t, n) {
|
152
|
+
function callInvokeWithMethodAndArg() {
|
153
|
+
return new e(function (e, r) {
|
154
|
+
invoke(t, n, e, r);
|
155
|
+
});
|
156
|
+
}
|
157
|
+
return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
|
151
158
|
}
|
152
|
-
|
153
|
-
};
|
159
|
+
});
|
154
160
|
}
|
155
|
-
function
|
156
|
-
var
|
157
|
-
|
158
|
-
if (
|
159
|
-
|
160
|
-
|
161
|
+
function makeInvokeMethod(e, r, n) {
|
162
|
+
var o = h;
|
163
|
+
return function (i, a) {
|
164
|
+
if (o === f) throw new Error("Generator is already running");
|
165
|
+
if (o === s) {
|
166
|
+
if ("throw" === i) throw a;
|
167
|
+
return {
|
168
|
+
value: t,
|
169
|
+
done: !0
|
170
|
+
};
|
171
|
+
}
|
172
|
+
for (n.method = i, n.arg = a;;) {
|
173
|
+
var c = n.delegate;
|
174
|
+
if (c) {
|
175
|
+
var u = maybeInvokeDelegate(c, n);
|
176
|
+
if (u) {
|
177
|
+
if (u === y) continue;
|
178
|
+
return u;
|
179
|
+
}
|
180
|
+
}
|
181
|
+
if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) {
|
182
|
+
if (o === h) throw o = s, n.arg;
|
183
|
+
n.dispatchException(n.arg);
|
184
|
+
} else "return" === n.method && n.abrupt("return", n.arg);
|
185
|
+
o = f;
|
186
|
+
var p = tryCatch(e, r, n);
|
187
|
+
if ("normal" === p.type) {
|
188
|
+
if (o = n.done ? s : l, p.arg === y) continue;
|
189
|
+
return {
|
190
|
+
value: p.arg,
|
191
|
+
done: n.done
|
192
|
+
};
|
193
|
+
}
|
194
|
+
"throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg);
|
161
195
|
}
|
162
|
-
|
163
|
-
}
|
164
|
-
var record = tryCatch(method, delegate.iterator, context.arg);
|
165
|
-
if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel;
|
166
|
-
var info = record.arg;
|
167
|
-
return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel);
|
196
|
+
};
|
168
197
|
}
|
169
|
-
function
|
170
|
-
var
|
171
|
-
|
198
|
+
function maybeInvokeDelegate(e, r) {
|
199
|
+
var n = r.method,
|
200
|
+
o = e.iterator[n];
|
201
|
+
if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y;
|
202
|
+
var i = tryCatch(o, e.iterator, r.arg);
|
203
|
+
if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y;
|
204
|
+
var a = i.arg;
|
205
|
+
return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y);
|
206
|
+
}
|
207
|
+
function pushTryEntry(t) {
|
208
|
+
var e = {
|
209
|
+
tryLoc: t[0]
|
172
210
|
};
|
173
|
-
1 in
|
211
|
+
1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e);
|
174
212
|
}
|
175
|
-
function resetTryEntry(
|
176
|
-
var
|
177
|
-
|
213
|
+
function resetTryEntry(t) {
|
214
|
+
var e = t.completion || {};
|
215
|
+
e.type = "normal", delete e.arg, t.completion = e;
|
178
216
|
}
|
179
|
-
function Context(
|
217
|
+
function Context(t) {
|
180
218
|
this.tryEntries = [{
|
181
219
|
tryLoc: "root"
|
182
|
-
}],
|
183
|
-
}
|
184
|
-
function values(
|
185
|
-
if (
|
186
|
-
var
|
187
|
-
if (
|
188
|
-
if ("function" == typeof
|
189
|
-
if (!isNaN(
|
190
|
-
var
|
191
|
-
|
192
|
-
for (; ++
|
193
|
-
return next.value =
|
220
|
+
}], t.forEach(pushTryEntry, this), this.reset(!0);
|
221
|
+
}
|
222
|
+
function values(e) {
|
223
|
+
if (e || "" === e) {
|
224
|
+
var r = e[a];
|
225
|
+
if (r) return r.call(e);
|
226
|
+
if ("function" == typeof e.next) return e;
|
227
|
+
if (!isNaN(e.length)) {
|
228
|
+
var o = -1,
|
229
|
+
i = function next() {
|
230
|
+
for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next;
|
231
|
+
return next.value = t, next.done = !0, next;
|
194
232
|
};
|
195
|
-
return
|
196
|
-
}
|
197
|
-
}
|
233
|
+
return i.next = i;
|
234
|
+
}
|
235
|
+
}
|
236
|
+
throw new TypeError(typeof e + " is not iterable");
|
237
|
+
}
|
238
|
+
return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
|
239
|
+
value: GeneratorFunctionPrototype,
|
240
|
+
configurable: !0
|
241
|
+
}), o(GeneratorFunctionPrototype, "constructor", {
|
242
|
+
value: GeneratorFunction,
|
243
|
+
configurable: !0
|
244
|
+
}), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
|
245
|
+
var e = "function" == typeof t && t.constructor;
|
246
|
+
return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
|
247
|
+
}, e.mark = function (t) {
|
248
|
+
return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t;
|
249
|
+
}, e.awrap = function (t) {
|
198
250
|
return {
|
199
|
-
|
251
|
+
__await: t
|
200
252
|
};
|
201
|
-
}
|
202
|
-
function doneResult() {
|
203
|
-
return {
|
204
|
-
value: undefined,
|
205
|
-
done: !0
|
206
|
-
};
|
207
|
-
}
|
208
|
-
return GeneratorFunction.prototype = GeneratorFunctionPrototype, define(Gp, "constructor", GeneratorFunctionPrototype), define(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) {
|
209
|
-
var ctor = "function" == typeof genFun && genFun.constructor;
|
210
|
-
return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name));
|
211
|
-
}, exports.mark = function (genFun) {
|
212
|
-
return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun;
|
213
|
-
}, exports.awrap = function (arg) {
|
214
|
-
return {
|
215
|
-
__await: arg
|
216
|
-
};
|
217
|
-
}, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
|
253
|
+
}, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () {
|
218
254
|
return this;
|
219
|
-
}),
|
220
|
-
void 0 ===
|
221
|
-
var
|
222
|
-
return
|
223
|
-
return
|
255
|
+
}), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) {
|
256
|
+
void 0 === i && (i = Promise);
|
257
|
+
var a = new AsyncIterator(wrap(t, r, n, o), i);
|
258
|
+
return e.isGeneratorFunction(r) ? a : a.next().then(function (t) {
|
259
|
+
return t.done ? t.value : a.next();
|
224
260
|
});
|
225
|
-
}, defineIteratorMethods(
|
261
|
+
}, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () {
|
226
262
|
return this;
|
227
|
-
}), define(
|
263
|
+
}), define(g, "toString", function () {
|
228
264
|
return "[object Generator]";
|
229
|
-
}),
|
230
|
-
var
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
265
|
+
}), e.keys = function (t) {
|
266
|
+
var e = Object(t),
|
267
|
+
r = [];
|
268
|
+
for (var n in e) r.push(n);
|
269
|
+
return r.reverse(), function next() {
|
270
|
+
for (; r.length;) {
|
271
|
+
var t = r.pop();
|
272
|
+
if (t in e) return next.value = t, next.done = !1, next;
|
236
273
|
}
|
237
274
|
return next.done = !0, next;
|
238
275
|
};
|
239
|
-
},
|
276
|
+
}, e.values = values, Context.prototype = {
|
240
277
|
constructor: Context,
|
241
|
-
reset: function (
|
242
|
-
if (this.prev = 0, this.next = 0, this.sent = this._sent =
|
278
|
+
reset: function (e) {
|
279
|
+
if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
|
243
280
|
},
|
244
281
|
stop: function () {
|
245
282
|
this.done = !0;
|
246
|
-
var
|
247
|
-
if ("throw" ===
|
283
|
+
var t = this.tryEntries[0].completion;
|
284
|
+
if ("throw" === t.type) throw t.arg;
|
248
285
|
return this.rval;
|
249
286
|
},
|
250
|
-
dispatchException: function (
|
251
|
-
if (this.done) throw
|
252
|
-
var
|
253
|
-
function handle(
|
254
|
-
return
|
255
|
-
}
|
256
|
-
for (var
|
257
|
-
var
|
258
|
-
|
259
|
-
if ("root" ===
|
260
|
-
if (
|
261
|
-
var
|
262
|
-
|
263
|
-
if (
|
264
|
-
if (this.prev <
|
265
|
-
if (this.prev <
|
266
|
-
} else if (
|
267
|
-
if (this.prev <
|
287
|
+
dispatchException: function (e) {
|
288
|
+
if (this.done) throw e;
|
289
|
+
var r = this;
|
290
|
+
function handle(n, o) {
|
291
|
+
return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o;
|
292
|
+
}
|
293
|
+
for (var o = this.tryEntries.length - 1; o >= 0; --o) {
|
294
|
+
var i = this.tryEntries[o],
|
295
|
+
a = i.completion;
|
296
|
+
if ("root" === i.tryLoc) return handle("end");
|
297
|
+
if (i.tryLoc <= this.prev) {
|
298
|
+
var c = n.call(i, "catchLoc"),
|
299
|
+
u = n.call(i, "finallyLoc");
|
300
|
+
if (c && u) {
|
301
|
+
if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
|
302
|
+
if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
|
303
|
+
} else if (c) {
|
304
|
+
if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
|
268
305
|
} else {
|
269
|
-
if (!
|
270
|
-
if (this.prev <
|
306
|
+
if (!u) throw new Error("try statement without catch or finally");
|
307
|
+
if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
|
271
308
|
}
|
272
309
|
}
|
273
310
|
}
|
274
311
|
},
|
275
|
-
abrupt: function (
|
276
|
-
for (var
|
277
|
-
var
|
278
|
-
if (
|
279
|
-
var
|
312
|
+
abrupt: function (t, e) {
|
313
|
+
for (var r = this.tryEntries.length - 1; r >= 0; --r) {
|
314
|
+
var o = this.tryEntries[r];
|
315
|
+
if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) {
|
316
|
+
var i = o;
|
280
317
|
break;
|
281
318
|
}
|
282
319
|
}
|
283
|
-
|
284
|
-
var
|
285
|
-
return
|
320
|
+
i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null);
|
321
|
+
var a = i ? i.completion : {};
|
322
|
+
return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a);
|
286
323
|
},
|
287
|
-
complete: function (
|
288
|
-
if ("throw" ===
|
289
|
-
return "break" ===
|
324
|
+
complete: function (t, e) {
|
325
|
+
if ("throw" === t.type) throw t.arg;
|
326
|
+
return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y;
|
290
327
|
},
|
291
|
-
finish: function (
|
292
|
-
for (var
|
293
|
-
var
|
294
|
-
if (
|
328
|
+
finish: function (t) {
|
329
|
+
for (var e = this.tryEntries.length - 1; e >= 0; --e) {
|
330
|
+
var r = this.tryEntries[e];
|
331
|
+
if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y;
|
295
332
|
}
|
296
333
|
},
|
297
|
-
catch: function (
|
298
|
-
for (var
|
299
|
-
var
|
300
|
-
if (
|
301
|
-
var
|
302
|
-
if ("throw" ===
|
303
|
-
var
|
304
|
-
resetTryEntry(
|
334
|
+
catch: function (t) {
|
335
|
+
for (var e = this.tryEntries.length - 1; e >= 0; --e) {
|
336
|
+
var r = this.tryEntries[e];
|
337
|
+
if (r.tryLoc === t) {
|
338
|
+
var n = r.completion;
|
339
|
+
if ("throw" === n.type) {
|
340
|
+
var o = n.arg;
|
341
|
+
resetTryEntry(r);
|
305
342
|
}
|
306
|
-
return
|
343
|
+
return o;
|
307
344
|
}
|
308
345
|
}
|
309
346
|
throw new Error("illegal catch attempt");
|
310
347
|
},
|
311
|
-
delegateYield: function (
|
348
|
+
delegateYield: function (e, r, n) {
|
312
349
|
return this.delegate = {
|
313
|
-
iterator: values(
|
314
|
-
resultName:
|
315
|
-
nextLoc:
|
316
|
-
}, "next" === this.method && (this.arg =
|
350
|
+
iterator: values(e),
|
351
|
+
resultName: r,
|
352
|
+
nextLoc: n
|
353
|
+
}, "next" === this.method && (this.arg = t), y;
|
317
354
|
}
|
318
|
-
},
|
355
|
+
}, e;
|
356
|
+
}
|
357
|
+
function _toPrimitive(t, r) {
|
358
|
+
if ("object" != typeof t || !t) return t;
|
359
|
+
var e = t[Symbol.toPrimitive];
|
360
|
+
if (void 0 !== e) {
|
361
|
+
var i = e.call(t, r || "default");
|
362
|
+
if ("object" != typeof i) return i;
|
363
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
364
|
+
}
|
365
|
+
return ("string" === r ? String : Number)(t);
|
366
|
+
}
|
367
|
+
function _toPropertyKey(t) {
|
368
|
+
var i = _toPrimitive(t, "string");
|
369
|
+
return "symbol" == typeof i ? i : String(i);
|
319
370
|
}
|
320
|
-
function _typeof(
|
371
|
+
function _typeof(o) {
|
321
372
|
"@babel/helpers - typeof";
|
322
373
|
|
323
|
-
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (
|
324
|
-
return typeof
|
325
|
-
} : function (
|
326
|
-
return
|
327
|
-
}, _typeof(
|
374
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
|
375
|
+
return typeof o;
|
376
|
+
} : function (o) {
|
377
|
+
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
378
|
+
}, _typeof(o);
|
328
379
|
}
|
329
380
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
|
330
381
|
try {
|
@@ -367,7 +418,7 @@
|
|
367
418
|
descriptor.enumerable = descriptor.enumerable || false;
|
368
419
|
descriptor.configurable = true;
|
369
420
|
if ("value" in descriptor) descriptor.writable = true;
|
370
|
-
Object.defineProperty(target, descriptor.key, descriptor);
|
421
|
+
Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor);
|
371
422
|
}
|
372
423
|
}
|
373
424
|
function _createClass(Constructor, protoProps, staticProps) {
|
@@ -379,6 +430,7 @@
|
|
379
430
|
return Constructor;
|
380
431
|
}
|
381
432
|
function _defineProperty(obj, key, value) {
|
433
|
+
key = _toPropertyKey(key);
|
382
434
|
if (key in obj) {
|
383
435
|
Object.defineProperty(obj, key, {
|
384
436
|
value: value,
|
@@ -409,30 +461,6 @@
|
|
409
461
|
function _iterableToArray(iter) {
|
410
462
|
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
411
463
|
}
|
412
|
-
function _iterableToArrayLimit(arr, i) {
|
413
|
-
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
414
|
-
if (_i == null) return;
|
415
|
-
var _arr = [];
|
416
|
-
var _n = true;
|
417
|
-
var _d = false;
|
418
|
-
var _s, _e;
|
419
|
-
try {
|
420
|
-
for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
|
421
|
-
_arr.push(_s.value);
|
422
|
-
if (i && _arr.length === i) break;
|
423
|
-
}
|
424
|
-
} catch (err) {
|
425
|
-
_d = true;
|
426
|
-
_e = err;
|
427
|
-
} finally {
|
428
|
-
try {
|
429
|
-
if (!_n && _i["return"] != null) _i["return"]();
|
430
|
-
} finally {
|
431
|
-
if (_d) throw _e;
|
432
|
-
}
|
433
|
-
}
|
434
|
-
return _arr;
|
435
|
-
}
|
436
464
|
function _unsupportedIterableToArray(o, minLen) {
|
437
465
|
if (!o) return;
|
438
466
|
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
@@ -766,8 +794,8 @@
|
|
766
794
|
*
|
767
795
|
* @returns {Object} Result of all merge properties
|
768
796
|
*/
|
769
|
-
function /* obj1, obj2, obj3, ... */
|
770
|
-
|
797
|
+
function merge( /* obj1, obj2, obj3, ... */
|
798
|
+
) {
|
771
799
|
var _ref2 = isContextDefined(this) && this || {},
|
772
800
|
caseless = _ref2.caseless;
|
773
801
|
var result = {};
|
@@ -1774,9 +1802,6 @@
|
|
1774
1802
|
}
|
1775
1803
|
var isFormData = utils$1.isFormData(data);
|
1776
1804
|
if (isFormData) {
|
1777
|
-
if (!hasJSONContentType) {
|
1778
|
-
return data;
|
1779
|
-
}
|
1780
1805
|
return hasJSONContentType ? JSON.stringify(formDataToJSON(data)) : data;
|
1781
1806
|
}
|
1782
1807
|
if (utils$1.isArrayBuffer(data) || utils$1.isBuffer(data) || utils$1.isStream(data) || utils$1.isFile(data) || utils$1.isBlob(data)) {
|
@@ -2738,7 +2763,7 @@
|
|
2738
2763
|
}
|
2739
2764
|
|
2740
2765
|
var headersToObject = function headersToObject(thing) {
|
2741
|
-
return thing instanceof AxiosHeaders$1 ? thing
|
2766
|
+
return thing instanceof AxiosHeaders$1 ? _objectSpread2({}, thing) : thing;
|
2742
2767
|
};
|
2743
2768
|
|
2744
2769
|
/**
|
@@ -2841,7 +2866,7 @@
|
|
2841
2866
|
return config;
|
2842
2867
|
}
|
2843
2868
|
|
2844
|
-
var VERSION = "1.6.
|
2869
|
+
var VERSION = "1.6.8";
|
2845
2870
|
|
2846
2871
|
var validators$1 = {};
|
2847
2872
|
|
@@ -2947,38 +2972,36 @@
|
|
2947
2972
|
*/
|
2948
2973
|
_createClass(Axios, [{
|
2949
2974
|
key: "request",
|
2950
|
-
value: function () {
|
2975
|
+
value: (function () {
|
2951
2976
|
var _request2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(configOrUrl, config) {
|
2952
|
-
var dummy;
|
2977
|
+
var dummy, stack;
|
2953
2978
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
2954
|
-
while (1) {
|
2955
|
-
|
2956
|
-
|
2957
|
-
|
2958
|
-
|
2959
|
-
|
2960
|
-
|
2961
|
-
|
2962
|
-
|
2963
|
-
|
2964
|
-
|
2965
|
-
dummy = {};
|
2966
|
-
|
2967
|
-
Error.captureStackTrace(dummy);
|
2968
|
-
} else {
|
2969
|
-
dummy.stack = new Error().stack;
|
2970
|
-
}
|
2979
|
+
while (1) switch (_context.prev = _context.next) {
|
2980
|
+
case 0:
|
2981
|
+
_context.prev = 0;
|
2982
|
+
_context.next = 3;
|
2983
|
+
return this._request(configOrUrl, config);
|
2984
|
+
case 3:
|
2985
|
+
return _context.abrupt("return", _context.sent);
|
2986
|
+
case 6:
|
2987
|
+
_context.prev = 6;
|
2988
|
+
_context.t0 = _context["catch"](0);
|
2989
|
+
if (_context.t0 instanceof Error) {
|
2990
|
+
Error.captureStackTrace ? Error.captureStackTrace(dummy = {}) : dummy = new Error();
|
2991
|
+
|
2971
2992
|
// slice off the Error: ... line
|
2972
|
-
dummy.stack
|
2973
|
-
|
2974
|
-
|
2975
|
-
|
2993
|
+
stack = dummy.stack ? dummy.stack.replace(/^.+\n/, '') : '';
|
2994
|
+
if (!_context.t0.stack) {
|
2995
|
+
_context.t0.stack = stack;
|
2996
|
+
// match without the 2 top stack lines
|
2997
|
+
} else if (stack && !String(_context.t0.stack).endsWith(stack.replace(/^.+\n.+\n/, ''))) {
|
2998
|
+
_context.t0.stack += '\n' + stack;
|
2976
2999
|
}
|
2977
|
-
|
2978
|
-
|
2979
|
-
|
2980
|
-
|
2981
|
-
|
3000
|
+
}
|
3001
|
+
throw _context.t0;
|
3002
|
+
case 10:
|
3003
|
+
case "end":
|
3004
|
+
return _context.stop();
|
2982
3005
|
}
|
2983
3006
|
}, _callee, this, [[0, 6]]);
|
2984
3007
|
}));
|
@@ -2986,7 +3009,7 @@
|
|
2986
3009
|
return _request2.apply(this, arguments);
|
2987
3010
|
}
|
2988
3011
|
return request;
|
2989
|
-
}()
|
3012
|
+
}())
|
2990
3013
|
}, {
|
2991
3014
|
key: "_request",
|
2992
3015
|
value: function _request(configOrUrl, config) {
|