@ancon/wildcat-utils 1.23.0 → 1.23.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.
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("@ancon/wildcat-types"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("@ancon/wildcat-types"),f=require("./getCheckoutItemsMappedByTicketItemStatus.js");var O=(e=>(e.YourOrderIsBeingProcessed="yourOrderIsBeingProcessed",e.YourOrderWasCancelled="yourOrderWasCancelled",e.ProcessingPayment="processingPayment",e.YourOrderIsBeingPrepared="yourOrderIsBeingPrepared",e.YourOrderIsReadyToCollect="yourOrderIsReadyToCollect",e.YourOrderIsBeingDelivered="yourOrderIsBeingDelivered",e.YourOrderHasBeenCompleted="yourOrderHasBeenCompleted",e.YourOrderWillArriveAtYourTable="yourOrderWillArriveAtYourTable",e.ModifiedDeliveryStartTime="modifiedDeliveryStartTime",e.ModifiedPickUpTime="modifiedPickUpTime",e.YourOrderHasBeenAcceptedEstimatedDeliveryStartTime="yourOrderHasBeenAcceptedEstimatedDeliveryStartTime",e.YourOrderIsBeingPreparedEstimatedDeliveryStartTime="yourOrderIsBeingPreparedEstimatedDeliveryStartTime",e.YourOrderHasBeenAcceptedEstimatedTime="yourOrderHasBeenAcceptedEstimatedTime",e.YourOrderHasBeenAcceptedPickupTime="yourOrderHasBeenAcceptedPickupTime",e.DeliveryWasCompleted="deliveryWasCompleted",e.OneItemIsReadyToCollect="oneItemIsReadyToCollect",e.MultipleItemsAreReadyToCollect="multipleItemsAreReadyToCollect",e.EnjoyMealWhileOtherItemsBeingPrepared="enjoyMealWhileOtherItemsBeingPrepared",e))(O||{});function C(e,i){switch(e){case r.CheckoutStatus.Created:case r.CheckoutStatus.Ready:case r.CheckoutStatus.Processing:case r.CheckoutStatus.Authorized:return"yourOrderIsBeingProcessed";case r.CheckoutStatus.Canceled:return"yourOrderWasCancelled";case r.CheckoutStatus.Received:return"processingPayment";case r.CheckoutStatus.ReadyToCollect:return i?"yourOrderIsBeingDelivered":"yourOrderIsReadyToCollect";default:return null}}function T(e){switch(e){case r.TicketStatus.Pending:case r.TicketStatus.PendingAccept:return"yourOrderIsBeingProcessed";case r.TicketStatus.Preparing:return"yourOrderIsBeingPrepared";case r.TicketStatus.Ready:return"yourOrderIsReadyToCollect";case r.TicketStatus.Closed:return"yourOrderHasBeenCompleted";case r.TicketStatus.Canceled:return"yourOrderWasCancelled";default:throw new Error(`Unhandled ticket status "${e}" in getTranslationKeyByTicketStatus()`)}}function I(e,{checkoutStatus:i,ticketStatus:o,customersFetchTableOrders:d}){const a=(e==null?void 0:e.orderFormat)===r.OrderFormat.Delivery,s=(e==null?void 0:e.orderFormat)===r.OrderFormat.TakeAway,t=(e==null?void 0:e.orderFormat)===r.OrderFormat.TableOrder;if(a||s||t&&!d)return!1;const l=i!=null,c=o!=null;if(l){const n=i===r.CheckoutStatus.Captured,u=i===r.CheckoutStatus.InProgress;return n||u}if(c){const n=o===r.TicketStatus.Preparing,u=o===r.TicketStatus.Ready;return n||u}return!1}function P(e,{checkoutStatus:i,ticketStatus:o,customersFetchTableOrders:d,pickupTimeUpdated:a,isSkipTicketStatus:s},t){if(t&&I(e,{checkoutStatus:i,ticketStatus:o,customersFetchTableOrders:d})){if(t.ready>0)return t.ready<2?["oneItemIsReadyToCollect"]:["multipleItemsAreReadyToCollect",{count:t.ready}];if(t.done>0&&t.done<t.all)return["enjoyMealWhileOtherItemsBeingPrepared",{count:Math.max(0,t.all-t.done-t.ready)}]}if(o!=null&&!s)return[T(o)];const l=(e==null?void 0:e.orderFormat)===r.OrderFormat.Delivery,c=C(i,l);if(c)return[c];const n=i===r.CheckoutStatus.Captured,u=i===r.CheckoutStatus.InProgress,m=i===r.CheckoutStatus.Done,y=(e==null?void 0:e.orderFormat)===r.OrderFormat.EatIn,p=(e==null?void 0:e.orderFormat)===r.OrderFormat.TakeAway,g=(e==null?void 0:e.orderFormat)===r.OrderFormat.TableOrder;if(n)return g&&!d?["yourOrderWillArriveAtYourTable"]:l?a?["modifiedDeliveryStartTime"]:["yourOrderHasBeenAcceptedEstimatedDeliveryStartTime"]:a?["modifiedPickUpTime"]:["yourOrderHasBeenAcceptedPickupTime"];if(u){if(l)return a?["modifiedDeliveryStartTime"]:["yourOrderIsBeingPreparedEstimatedDeliveryStartTime"];if(t&&(y||p)){if(t.ready===t.all)return["yourOrderIsReadyToCollect"];if(t.done===t.all)return["yourOrderHasBeenCompleted"]}if(g){if(t){if(t.ready===t.all)return d?["yourOrderIsReadyToCollect"]:["yourOrderWillArriveAtYourTable"];if(t.done===t.all)return d?["yourOrderHasBeenCompleted"]:["yourOrderWillArriveAtYourTable"]}return a?["modifiedPickUpTime"]:d?["yourOrderIsBeingPrepared"]:["yourOrderWillArriveAtYourTable"]}return a?["modifiedPickUpTime"]:["yourOrderIsBeingPrepared"]}if(m)return y||p?["yourOrderHasBeenCompleted"]:l?["deliveryWasCompleted"]:["yourOrderHasBeenCompleted"];throw new Error("Could not resolve translation key in getTranslationKey()")}const B={yourOrderIsBeingProcessed:()=>({title:"Your order is being processed"}),yourOrderWasCancelled:()=>({title:"Your order was canceled",message:"Sorry. Your order could not go through."}),processingPayment:()=>({title:"Processing payment",message:"Please wait while your payment is being processed"}),yourOrderIsBeingPrepared:()=>({title:"Your order is now being prepared!",message:"We will let you know when it is ready for pickup."}),yourOrderIsReadyToCollect:()=>({title:"Your order is ready to be collected!",message:"Please go ahead and show this screen at the collection point"}),yourOrderIsBeingDelivered:()=>({title:"Your order is being delivered",message:"It will arrive at your door shortly. Enjoy your meal!"}),yourOrderHasBeenCompleted:()=>({title:"Enjoy your meal!",message:"Your order has been completed!"}),yourOrderWillArriveAtYourTable:()=>({title:"Your order has been accepted!",message:"It will arrive at your table shortly"}),modifiedDeliveryStartTime:()=>({title:"Your delivery time was modified",message:"Delivery will start at approximately 00:00."}),modifiedPickUpTime:()=>({title:"Your pickup time was modified",message:"Pickup time: 00:00"}),yourOrderHasBeenAcceptedEstimatedDeliveryStartTime:()=>({title:"Your order has been accepted",message:"Estimated delivery start time: 00:00"}),yourOrderIsBeingPreparedEstimatedDeliveryStartTime:()=>({title:"Your order is now being prepared!",message:"Estimated delivery start time: 00:00"}),yourOrderHasBeenAcceptedEstimatedTime:()=>({title:"Your order has been accepted",message:"Estimated time: 00:00"}),yourOrderHasBeenAcceptedPickupTime:()=>({title:"Your order has been accepted",message:"Pickup time: 00:00"}),deliveryWasCompleted:()=>({title:"Your order was completed",message:"Enjoy your meal!"}),oneItemIsReadyToCollect:()=>({title:"One item is ready to pick up!",message:"Please allow cashier or waiter to confirm that the prepared item has been successfully issued."}),multipleItemsAreReadyToCollect:()=>({title:"Multiple items are ready to pick up!",message:"Please allow cashier or waiter to confirm that the prepared items have been successfully issued."}),enjoyMealWhileOtherItemsBeingPrepared:({meta:e})=>({title:"Enjoy your meal while the rest of the items are being prepared!",message:`${e.count} more items are being prepared`})};function h(e,i){if(i)return;const o=f(e);return{all:o.all.length,ready:o.ready.length,done:o.done.length}}function v(e,i,o=B){const{isSkipTicketStatus:d}=i,a=h((e==null?void 0:e.items)??[],d),[s,t]=P(e,i,a),l=o[s]({key:s,meta:t});if(!l)throw new Error("Could not resolve translation in getOrderStatusTexts()");return[l,s]}exports.TranslationKey=O;exports.default=v;
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { OrderFormat as
|
|
2
|
-
import
|
|
3
|
-
var
|
|
4
|
-
function
|
|
1
|
+
import { OrderFormat as u, CheckoutStatus as o, TicketStatus as s } from "@ancon/wildcat-types";
|
|
2
|
+
import I from "./getCheckoutItemsMappedByTicketItemStatus.mjs";
|
|
3
|
+
var P = /* @__PURE__ */ ((e) => (e.YourOrderIsBeingProcessed = "yourOrderIsBeingProcessed", e.YourOrderWasCancelled = "yourOrderWasCancelled", e.ProcessingPayment = "processingPayment", e.YourOrderIsBeingPrepared = "yourOrderIsBeingPrepared", e.YourOrderIsReadyToCollect = "yourOrderIsReadyToCollect", e.YourOrderIsBeingDelivered = "yourOrderIsBeingDelivered", e.YourOrderHasBeenCompleted = "yourOrderHasBeenCompleted", e.YourOrderWillArriveAtYourTable = "yourOrderWillArriveAtYourTable", e.ModifiedDeliveryStartTime = "modifiedDeliveryStartTime", e.ModifiedPickUpTime = "modifiedPickUpTime", e.YourOrderHasBeenAcceptedEstimatedDeliveryStartTime = "yourOrderHasBeenAcceptedEstimatedDeliveryStartTime", e.YourOrderIsBeingPreparedEstimatedDeliveryStartTime = "yourOrderIsBeingPreparedEstimatedDeliveryStartTime", e.YourOrderHasBeenAcceptedEstimatedTime = "yourOrderHasBeenAcceptedEstimatedTime", e.YourOrderHasBeenAcceptedPickupTime = "yourOrderHasBeenAcceptedPickupTime", e.DeliveryWasCompleted = "deliveryWasCompleted", e.OneItemIsReadyToCollect = "oneItemIsReadyToCollect", e.MultipleItemsAreReadyToCollect = "multipleItemsAreReadyToCollect", e.EnjoyMealWhileOtherItemsBeingPrepared = "enjoyMealWhileOtherItemsBeingPrepared", e))(P || {});
|
|
4
|
+
function C(e, t) {
|
|
5
5
|
switch (e) {
|
|
6
|
-
case
|
|
7
|
-
case
|
|
8
|
-
case
|
|
9
|
-
case
|
|
6
|
+
case o.Created:
|
|
7
|
+
case o.Ready:
|
|
8
|
+
case o.Processing:
|
|
9
|
+
case o.Authorized:
|
|
10
10
|
return "yourOrderIsBeingProcessed";
|
|
11
|
-
case
|
|
11
|
+
case o.Canceled:
|
|
12
12
|
return "yourOrderWasCancelled";
|
|
13
|
-
case
|
|
13
|
+
case o.Received:
|
|
14
14
|
return "processingPayment";
|
|
15
|
-
case
|
|
15
|
+
case o.ReadyToCollect:
|
|
16
16
|
return t ? "yourOrderIsBeingDelivered" : "yourOrderIsReadyToCollect";
|
|
17
17
|
default:
|
|
18
18
|
return null;
|
|
19
19
|
}
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function B(e) {
|
|
22
22
|
switch (e) {
|
|
23
23
|
case s.Pending:
|
|
24
24
|
case s.PendingAccept:
|
|
@@ -37,35 +37,36 @@ function C(e) {
|
|
|
37
37
|
);
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
|
-
function
|
|
40
|
+
function T(e, {
|
|
41
41
|
checkoutStatus: t,
|
|
42
|
-
ticketStatus:
|
|
43
|
-
customersFetchTableOrders:
|
|
42
|
+
ticketStatus: i,
|
|
43
|
+
customersFetchTableOrders: d
|
|
44
44
|
}) {
|
|
45
|
-
const
|
|
46
|
-
if (
|
|
45
|
+
const a = (e == null ? void 0 : e.orderFormat) === u.Delivery, n = (e == null ? void 0 : e.orderFormat) === u.TakeAway, r = (e == null ? void 0 : e.orderFormat) === u.TableOrder;
|
|
46
|
+
if (a || n || r && !d)
|
|
47
47
|
return !1;
|
|
48
|
-
const
|
|
49
|
-
if (
|
|
50
|
-
const
|
|
51
|
-
return
|
|
48
|
+
const l = t != null, p = i != null;
|
|
49
|
+
if (l) {
|
|
50
|
+
const c = t === o.Captured, y = t === o.InProgress;
|
|
51
|
+
return c || y;
|
|
52
52
|
}
|
|
53
53
|
if (p) {
|
|
54
|
-
const
|
|
55
|
-
return
|
|
54
|
+
const c = i === s.Preparing, y = i === s.Ready;
|
|
55
|
+
return c || y;
|
|
56
56
|
}
|
|
57
57
|
return !1;
|
|
58
58
|
}
|
|
59
|
-
function
|
|
59
|
+
function v(e, {
|
|
60
60
|
checkoutStatus: t,
|
|
61
|
-
ticketStatus:
|
|
62
|
-
customersFetchTableOrders:
|
|
63
|
-
pickupTimeUpdated:
|
|
61
|
+
ticketStatus: i,
|
|
62
|
+
customersFetchTableOrders: d,
|
|
63
|
+
pickupTimeUpdated: a,
|
|
64
|
+
isSkipTicketStatus: n
|
|
64
65
|
}, r) {
|
|
65
|
-
if (
|
|
66
|
+
if (r && T(e, {
|
|
66
67
|
checkoutStatus: t,
|
|
67
|
-
ticketStatus:
|
|
68
|
-
customersFetchTableOrders:
|
|
68
|
+
ticketStatus: i,
|
|
69
|
+
customersFetchTableOrders: d
|
|
69
70
|
})) {
|
|
70
71
|
if (r.ready > 0)
|
|
71
72
|
return r.ready < 2 ? ["oneItemIsReadyToCollect"] : [
|
|
@@ -78,30 +79,42 @@ function T(e, {
|
|
|
78
79
|
{ count: Math.max(0, r.all - r.done - r.ready) }
|
|
79
80
|
];
|
|
80
81
|
}
|
|
81
|
-
if (
|
|
82
|
-
return [
|
|
83
|
-
const
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
82
|
+
if (i != null && !n)
|
|
83
|
+
return [B(i)];
|
|
84
|
+
const l = (e == null ? void 0 : e.orderFormat) === u.Delivery, p = C(
|
|
85
|
+
t,
|
|
86
|
+
l
|
|
87
|
+
);
|
|
87
88
|
if (p)
|
|
88
|
-
return
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
89
|
+
return [p];
|
|
90
|
+
const c = t === o.Captured, y = t === o.InProgress, O = t === o.Done, g = (e == null ? void 0 : e.orderFormat) === u.EatIn, f = (e == null ? void 0 : e.orderFormat) === u.TakeAway, m = (e == null ? void 0 : e.orderFormat) === u.TableOrder;
|
|
91
|
+
if (c)
|
|
92
|
+
return m && !d ? ["yourOrderWillArriveAtYourTable"] : l ? a ? ["modifiedDeliveryStartTime"] : ["yourOrderHasBeenAcceptedEstimatedDeliveryStartTime"] : a ? ["modifiedPickUpTime"] : ["yourOrderHasBeenAcceptedPickupTime"];
|
|
93
|
+
if (y) {
|
|
94
|
+
if (l)
|
|
95
|
+
return a ? ["modifiedDeliveryStartTime"] : ["yourOrderIsBeingPreparedEstimatedDeliveryStartTime"];
|
|
96
|
+
if (r && (g || f)) {
|
|
93
97
|
if (r.ready === r.all)
|
|
94
98
|
return ["yourOrderIsReadyToCollect"];
|
|
95
99
|
if (r.done === r.all)
|
|
96
100
|
return ["yourOrderHasBeenCompleted"];
|
|
97
101
|
}
|
|
98
|
-
|
|
102
|
+
if (m) {
|
|
103
|
+
if (r) {
|
|
104
|
+
if (r.ready === r.all)
|
|
105
|
+
return d ? ["yourOrderIsReadyToCollect"] : ["yourOrderWillArriveAtYourTable"];
|
|
106
|
+
if (r.done === r.all)
|
|
107
|
+
return d ? ["yourOrderHasBeenCompleted"] : ["yourOrderWillArriveAtYourTable"];
|
|
108
|
+
}
|
|
109
|
+
return a ? ["modifiedPickUpTime"] : d ? ["yourOrderIsBeingPrepared"] : ["yourOrderWillArriveAtYourTable"];
|
|
110
|
+
}
|
|
111
|
+
return a ? ["modifiedPickUpTime"] : ["yourOrderIsBeingPrepared"];
|
|
99
112
|
}
|
|
100
|
-
if (
|
|
101
|
-
return g ||
|
|
113
|
+
if (O)
|
|
114
|
+
return g || f ? ["yourOrderHasBeenCompleted"] : l ? ["deliveryWasCompleted"] : ["yourOrderHasBeenCompleted"];
|
|
102
115
|
throw new Error("Could not resolve translation key in getTranslationKey()");
|
|
103
116
|
}
|
|
104
|
-
const
|
|
117
|
+
const h = {
|
|
105
118
|
yourOrderIsBeingProcessed: () => ({
|
|
106
119
|
title: "Your order is being processed"
|
|
107
120
|
}),
|
|
@@ -174,19 +187,26 @@ const v = {
|
|
|
174
187
|
message: `${e.count} more items are being prepared`
|
|
175
188
|
})
|
|
176
189
|
};
|
|
177
|
-
function
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
190
|
+
function A(e, t) {
|
|
191
|
+
if (t)
|
|
192
|
+
return;
|
|
193
|
+
const i = I(e);
|
|
194
|
+
return {
|
|
195
|
+
all: i.all.length,
|
|
196
|
+
ready: i.ready.length,
|
|
197
|
+
done: i.done.length
|
|
198
|
+
};
|
|
199
|
+
}
|
|
200
|
+
function D(e, t, i = h) {
|
|
201
|
+
const { isSkipTicketStatus: d } = t, a = A(
|
|
202
|
+
(e == null ? void 0 : e.items) ?? [],
|
|
203
|
+
d
|
|
204
|
+
), [n, r] = v(e, t, a), l = i[n]({ key: n, meta: r });
|
|
205
|
+
if (!l)
|
|
186
206
|
throw new Error("Could not resolve translation in getOrderStatusTexts()");
|
|
187
|
-
return [
|
|
207
|
+
return [l, n];
|
|
188
208
|
}
|
|
189
209
|
export {
|
|
190
|
-
|
|
191
|
-
|
|
210
|
+
P as TranslationKey,
|
|
211
|
+
D as default
|
|
192
212
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use strict";var dr=Object.defineProperty;var hr=(r,e,t)=>e in r?dr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t;var O=(r,e,t)=>(hr(r,typeof e!="symbol"?e+"":e,t),t);Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const k=require("@ancon/wildcat-types"),L=require("../error/createCodedError.js"),pr=require("../api/isNoContentResponse.js");function mr(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var le={},vr={get exports(){return le},set exports(r){le=r}},j={},Er={get exports(){return j},set exports(r){j=r}},ze=function(e,t){return function(){for(var n=new Array(arguments.length),s=0;s<n.length;s++)n[s]=arguments[s];return e.apply(t,n)}},yr=ze,de=Object.prototype.toString,he=function(r){return function(e){var t=de.call(e);return r[t]||(r[t]=t.slice(8,-1).toLowerCase())}}(Object.create(null));function S(r){return r=r.toLowerCase(),function(t){return he(t)===r}}function pe(r){return Array.isArray(r)}function M(r){return typeof r>"u"}function br(r){return r!==null&&!M(r)&&r.constructor!==null&&!M(r.constructor)&&typeof r.constructor.isBuffer=="function"&&r.constructor.isBuffer(r)}var Ge=S("ArrayBuffer");function Rr(r){var e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(r):e=r&&r.buffer&&Ge(r.buffer),e}function wr(r){return typeof r=="string"}function gr(r){return typeof r=="number"}function Je(r){return r!==null&&typeof r=="object"}function F(r){if(he(r)!=="object")return!1;var e=Object.getPrototypeOf(r);return e===null||e===Object.prototype}var Or=S("Date"),Sr=S("File"),xr=S("Blob"),Ar=S("FileList");function me(r){return de.call(r)==="[object Function]"}function Cr(r){return Je(r)&&me(r.pipe)}function Tr(r){var e="[object FormData]";return r&&(typeof FormData=="function"&&r instanceof FormData||de.call(r)===e||me(r.toString)&&r.toString()===e)}var Pr=S("URLSearchParams");function _r(r){return r.trim?r.trim():r.replace(/^\s+|\s+$/g,"")}function Nr(){return typeof navigator<"u"&&(navigator.product==="ReactNative"||navigator.product==="NativeScript"||navigator.product==="NS")?!1:typeof window<"u"&&typeof document<"u"}function ve(r,e){if(!(r===null||typeof r>"u"))if(typeof r!="object"&&(r=[r]),pe(r))for(var t=0,i=r.length;t<i;t++)e.call(null,r[t],t,r);else for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.call(null,r[n],n,r)}function ce(){var r={};function e(n,s){F(r[s])&&F(n)?r[s]=ce(r[s],n):F(n)?r[s]=ce({},n):pe(n)?r[s]=n.slice():r[s]=n}for(var t=0,i=arguments.length;t<i;t++)ve(arguments[t],e);return r}function qr(r,e,t){return ve(e,function(n,s){t&&typeof n=="function"?r[s]=yr(n,t):r[s]=n}),r}function Dr(r){return r.charCodeAt(0)===65279&&(r=r.slice(1)),r}function Ur(r,e,t,i){r.prototype=Object.create(e.prototype,i),r.prototype.constructor=r,t&&Object.assign(r.prototype,t)}function Br(r,e,t){var i,n,s,a={};e=e||{};do{for(i=Object.getOwnPropertyNames(r),n=i.length;n-- >0;)s=i[n],a[s]||(e[s]=r[s],a[s]=!0);r=Object.getPrototypeOf(r)}while(r&&(!t||t(r,e))&&r!==Object.prototype);return e}function kr(r,e,t){r=String(r),(t===void 0||t>r.length)&&(t=r.length),t-=e.length;var i=r.indexOf(e,t);return i!==-1&&i===t}function Lr(r){if(!r)return null;var e=r.length;if(M(e))return null;for(var t=new Array(e);e-- >0;)t[e]=r[e];return t}var Fr=function(r){return function(e){return r&&e instanceof r}}(typeof Uint8Array<"u"&&Object.getPrototypeOf(Uint8Array)),m={isArray:pe,isArrayBuffer:Ge,isBuffer:br,isFormData:Tr,isArrayBufferView:Rr,isString:wr,isNumber:gr,isObject:Je,isPlainObject:F,isUndefined:M,isDate:Or,isFile:Sr,isBlob:xr,isFunction:me,isStream:Cr,isURLSearchParams:Pr,isStandardBrowserEnv:Nr,forEach:ve,merge:ce,extend:qr,trim:_r,stripBOM:Dr,inherits:Ur,toFlatObject:Br,kindOf:he,kindOfTest:S,endsWith:kr,toArray:Lr,isTypedArray:Fr,isFileList:Ar},T=m;function ge(r){return encodeURIComponent(r).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var Ve=function(e,t,i){if(!t)return e;var n;if(i)n=i(t);else if(T.isURLSearchParams(t))n=t.toString();else{var s=[];T.forEach(t,function(f,d){f===null||typeof f>"u"||(T.isArray(f)?d=d+"[]":f=[f],T.forEach(f,function(h){T.isDate(h)?h=h.toISOString():T.isObject(h)&&(h=JSON.stringify(h)),s.push(ge(d)+"="+ge(h))}))}),n=s.join("&")}if(n){var a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+n}return e},$r=m;function H(){this.handlers=[]}H.prototype.use=function(e,t,i){return this.handlers.push({fulfilled:e,rejected:t,synchronous:i?i.synchronous:!1,runWhen:i?i.runWhen:null}),this.handlers.length-1};H.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)};H.prototype.forEach=function(e){$r.forEach(this.handlers,function(i){i!==null&&e(i)})};var jr=H,Mr=m,Hr=function(e,t){Mr.forEach(e,function(n,s){s!==t&&s.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[s])})},Xe=m;function _(r,e,t,i,n){Error.call(this),this.message=r,this.name="AxiosError",e&&(this.code=e),t&&(this.config=t),i&&(this.request=i),n&&(this.response=n)}Xe.inherits(_,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var Ke=_.prototype,Qe={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED"].forEach(function(r){Qe[r]={value:r}});Object.defineProperties(_,Qe);Object.defineProperty(Ke,"isAxiosError",{value:!0});_.from=function(r,e,t,i,n,s){var a=Object.create(Ke);return Xe.toFlatObject(r,a,function(f){return f!==Error.prototype}),_.call(a,r.message,e,t,i,n),a.name=r.name,s&&Object.assign(a,s),a};var q=_,Ye={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},R=m;function Ir(r,e){e=e||new FormData;var t=[];function i(s){return s===null?"":R.isDate(s)?s.toISOString():R.isArrayBuffer(s)||R.isTypedArray(s)?typeof Blob=="function"?new Blob([s]):Buffer.from(s):s}function n(s,a){if(R.isPlainObject(s)||R.isArray(s)){if(t.indexOf(s)!==-1)throw Error("Circular reference detected in "+a);t.push(s),R.forEach(s,function(f,d){if(!R.isUndefined(f)){var c=a?a+"."+d:d,h;if(f&&!a&&typeof f=="object"){if(R.endsWith(d,"{}"))f=JSON.stringify(f);else if(R.endsWith(d,"[]")&&(h=R.toArray(f))){h.forEach(function(u){!R.isUndefined(u)&&e.append(c,i(u))});return}}n(f,c)}}),t.pop()}else e.append(a,i(s))}return n(r),e}var Ze=Ir,X,Oe;function Wr(){if(Oe)return X;Oe=1;var r=q;return X=function(t,i,n){var s=n.config.validateStatus;!n.status||!s||s(n.status)?t(n):i(new r("Request failed with status code "+n.status,[r.ERR_BAD_REQUEST,r.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))},X}var K,Se;function zr(){if(Se)return K;Se=1;var r=m;return K=r.isStandardBrowserEnv()?function(){return{write:function(i,n,s,a,o,f){var d=[];d.push(i+"="+encodeURIComponent(n)),r.isNumber(s)&&d.push("expires="+new Date(s).toGMTString()),r.isString(a)&&d.push("path="+a),r.isString(o)&&d.push("domain="+o),f===!0&&d.push("secure"),document.cookie=d.join("; ")},read:function(i){var n=document.cookie.match(new RegExp("(^|;\\s*)("+i+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove:function(i){this.write(i,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}(),K}var Gr=function(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)},Jr=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e},Vr=Gr,Xr=Jr,er=function(e,t){return e&&!Vr(t)?Xr(e,t):t},Q,xe;function Kr(){if(xe)return Q;xe=1;var r=m,e=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];return Q=function(i){var n={},s,a,o;return i&&r.forEach(i.split(`
|
|
2
|
-
`),function(d){if(o=d.indexOf(":"),s=r.trim(d.substr(0,o)).toLowerCase(),a=r.trim(d.substr(o+1)),s){if(n[s]&&e.indexOf(s)>=0)return;s==="set-cookie"?n[s]=(n[s]?n[s]:[]).concat([a]):n[s]=n[s]?n[s]+", "+a:a}}),n},Q}var Y,Ae;function Qr(){if(Ae)return Y;Ae=1;var r=m;return Y=r.isStandardBrowserEnv()?function(){var t=/(msie|trident)/i.test(navigator.userAgent),i=document.createElement("a"),n;function s(a){var o=a;return t&&(i.setAttribute("href",o),o=i.href),i.setAttribute("href",o),{href:i.href,protocol:i.protocol?i.protocol.replace(/:$/,""):"",host:i.host,search:i.search?i.search.replace(/^\?/,""):"",hash:i.hash?i.hash.replace(/^#/,""):"",hostname:i.hostname,port:i.port,pathname:i.pathname.charAt(0)==="/"?i.pathname:"/"+i.pathname}}return n=s(window.location.href),function(o){var f=r.isString(o)?s(o):o;return f.protocol===n.protocol&&f.host===n.host}}():function(){return function(){return!0}}(),Y}var Z,Ce;function I(){if(Ce)return Z;Ce=1;var r=q,e=m;function t(i){r.call(this,i??"canceled",r.ERR_CANCELED),this.name="CanceledError"}return e.inherits(t,r,{__CANCEL__:!0}),Z=t,Z}var ee,Te;function Yr(){return Te||(Te=1,ee=function(e){var t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}),ee}var re,Pe;function _e(){if(Pe)return re;Pe=1;var r=m,e=Wr(),t=zr(),i=Ve,n=er,s=Kr(),a=Qr(),o=Ye,f=q,d=I(),c=Yr();return re=function(u){return new Promise(function(ur,x){var D=u.data,U=u.headers,B=u.responseType,A;function be(){u.cancelToken&&u.cancelToken.unsubscribe(A),u.signal&&u.signal.removeEventListener("abort",A)}r.isFormData(D)&&r.isStandardBrowserEnv()&&delete U["Content-Type"];var l=new XMLHttpRequest;if(u.auth){var fr=u.auth.username||"",lr=u.auth.password?unescape(encodeURIComponent(u.auth.password)):"";U.Authorization="Basic "+btoa(fr+":"+lr)}var G=n(u.baseURL,u.url);l.open(u.method.toUpperCase(),i(G,u.params,u.paramsSerializer),!0),l.timeout=u.timeout;function Re(){if(l){var b="getAllResponseHeaders"in l?s(l.getAllResponseHeaders()):null,C=!B||B==="text"||B==="json"?l.responseText:l.response,g={data:C,status:l.status,statusText:l.statusText,headers:b,config:u,request:l};e(function(V){ur(V),be()},function(V){x(V),be()},g),l=null}}if("onloadend"in l?l.onloadend=Re:l.onreadystatechange=function(){!l||l.readyState!==4||l.status===0&&!(l.responseURL&&l.responseURL.indexOf("file:")===0)||setTimeout(Re)},l.onabort=function(){l&&(x(new f("Request aborted",f.ECONNABORTED,u,l)),l=null)},l.onerror=function(){x(new f("Network Error",f.ERR_NETWORK,u,l,l)),l=null},l.ontimeout=function(){var C=u.timeout?"timeout of "+u.timeout+"ms exceeded":"timeout exceeded",g=u.transitional||o;u.timeoutErrorMessage&&(C=u.timeoutErrorMessage),x(new f(C,g.clarifyTimeoutError?f.ETIMEDOUT:f.ECONNABORTED,u,l)),l=null},r.isStandardBrowserEnv()){var we=(u.withCredentials||a(G))&&u.xsrfCookieName?t.read(u.xsrfCookieName):void 0;we&&(U[u.xsrfHeaderName]=we)}"setRequestHeader"in l&&r.forEach(U,function(C,g){typeof D>"u"&&g.toLowerCase()==="content-type"?delete U[g]:l.setRequestHeader(g,C)}),r.isUndefined(u.withCredentials)||(l.withCredentials=!!u.withCredentials),B&&B!=="json"&&(l.responseType=u.responseType),typeof u.onDownloadProgress=="function"&&l.addEventListener("progress",u.onDownloadProgress),typeof u.onUploadProgress=="function"&&l.upload&&l.upload.addEventListener("progress",u.onUploadProgress),(u.cancelToken||u.signal)&&(A=function(b){l&&(x(!b||b&&b.type?new d:b),l.abort(),l=null)},u.cancelToken&&u.cancelToken.subscribe(A),u.signal&&(u.signal.aborted?A():u.signal.addEventListener("abort",A))),D||(D=null);var J=c(G);if(J&&["http","https","file"].indexOf(J)===-1){x(new f("Unsupported protocol "+J+":",f.ERR_BAD_REQUEST,u));return}l.send(D)})},re}var te,Ne;function Zr(){return Ne||(Ne=1,te=null),te}var p=m,qe=Hr,De=q,et=Ye,rt=Ze,tt={"Content-Type":"application/x-www-form-urlencoded"};function Ue(r,e){!p.isUndefined(r)&&p.isUndefined(r["Content-Type"])&&(r["Content-Type"]=e)}function nt(){var r;return(typeof XMLHttpRequest<"u"||typeof process<"u"&&Object.prototype.toString.call(process)==="[object process]")&&(r=_e()),r}function it(r,e,t){if(p.isString(r))try{return(e||JSON.parse)(r),p.trim(r)}catch(i){if(i.name!=="SyntaxError")throw i}return(t||JSON.stringify)(r)}var W={transitional:et,adapter:nt(),transformRequest:[function(e,t){if(qe(t,"Accept"),qe(t,"Content-Type"),p.isFormData(e)||p.isArrayBuffer(e)||p.isBuffer(e)||p.isStream(e)||p.isFile(e)||p.isBlob(e))return e;if(p.isArrayBufferView(e))return e.buffer;if(p.isURLSearchParams(e))return Ue(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString();var i=p.isObject(e),n=t&&t["Content-Type"],s;if((s=p.isFileList(e))||i&&n==="multipart/form-data"){var a=this.env&&this.env.FormData;return rt(s?{"files[]":e}:e,a&&new a)}else if(i||n==="application/json")return Ue(t,"application/json"),it(e);return e}],transformResponse:[function(e){var t=this.transitional||W.transitional,i=t&&t.silentJSONParsing,n=t&&t.forcedJSONParsing,s=!i&&this.responseType==="json";if(s||n&&p.isString(e)&&e.length)try{return JSON.parse(e)}catch(a){if(s)throw a.name==="SyntaxError"?De.from(a,De.ERR_BAD_RESPONSE,this,null,this.response):a}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Zr()},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};p.forEach(["delete","get","head"],function(e){W.headers[e]={}});p.forEach(["post","put","patch"],function(e){W.headers[e]=p.merge(tt)});var Ee=W,st=m,at=Ee,ot=function(e,t,i){var n=this||at;return st.forEach(i,function(a){e=a.call(n,e,t)}),e},ne,Be;function rr(){return Be||(Be=1,ne=function(e){return!!(e&&e.__CANCEL__)}),ne}var ke=m,ie=ot,ut=rr(),ft=Ee,lt=I();function se(r){if(r.cancelToken&&r.cancelToken.throwIfRequested(),r.signal&&r.signal.aborted)throw new lt}var ct=function(e){se(e),e.headers=e.headers||{},e.data=ie.call(e,e.data,e.headers,e.transformRequest),e.headers=ke.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),ke.forEach(["delete","get","head","post","put","patch","common"],function(n){delete e.headers[n]});var t=e.adapter||ft.adapter;return t(e).then(function(n){return se(e),n.data=ie.call(e,n.data,n.headers,e.transformResponse),n},function(n){return ut(n)||(se(e),n&&n.response&&(n.response.data=ie.call(e,n.response.data,n.response.headers,e.transformResponse))),Promise.reject(n)})},E=m,tr=function(e,t){t=t||{};var i={};function n(c,h){return E.isPlainObject(c)&&E.isPlainObject(h)?E.merge(c,h):E.isPlainObject(h)?E.merge({},h):E.isArray(h)?h.slice():h}function s(c){if(E.isUndefined(t[c])){if(!E.isUndefined(e[c]))return n(void 0,e[c])}else return n(e[c],t[c])}function a(c){if(!E.isUndefined(t[c]))return n(void 0,t[c])}function o(c){if(E.isUndefined(t[c])){if(!E.isUndefined(e[c]))return n(void 0,e[c])}else return n(void 0,t[c])}function f(c){if(c in t)return n(e[c],t[c]);if(c in e)return n(void 0,e[c])}var d={url:a,method:a,data:a,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:f};return E.forEach(Object.keys(e).concat(Object.keys(t)),function(h){var u=d[h]||s,y=u(h);E.isUndefined(y)&&u!==f||(i[h]=y)}),i},ae,Le;function nr(){return Le||(Le=1,ae={version:"0.27.2"}),ae}var dt=nr().version,w=q,ye={};["object","boolean","number","function","string","symbol"].forEach(function(r,e){ye[r]=function(i){return typeof i===r||"a"+(e<1?"n ":" ")+r}});var Fe={};ye.transitional=function(e,t,i){function n(s,a){return"[Axios v"+dt+"] Transitional option '"+s+"'"+a+(i?". "+i:"")}return function(s,a,o){if(e===!1)throw new w(n(a," has been removed"+(t?" in "+t:"")),w.ERR_DEPRECATED);return t&&!Fe[a]&&(Fe[a]=!0,console.warn(n(a," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(s,a,o):!0}};function ht(r,e,t){if(typeof r!="object")throw new w("options must be an object",w.ERR_BAD_OPTION_VALUE);for(var i=Object.keys(r),n=i.length;n-- >0;){var s=i[n],a=e[s];if(a){var o=r[s],f=o===void 0||a(o,s,r);if(f!==!0)throw new w("option "+s+" must be "+f,w.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new w("Unknown option "+s,w.ERR_BAD_OPTION)}}var pt={assertOptions:ht,validators:ye},ir=m,mt=Ve,$e=jr,je=ct,z=tr,vt=er,sr=pt,P=sr.validators;function N(r){this.defaults=r,this.interceptors={request:new $e,response:new $e}}N.prototype.request=function(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=z(this.defaults,t),t.method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var i=t.transitional;i!==void 0&&sr.assertOptions(i,{silentJSONParsing:P.transitional(P.boolean),forcedJSONParsing:P.transitional(P.boolean),clarifyTimeoutError:P.transitional(P.boolean)},!1);var n=[],s=!0;this.interceptors.request.forEach(function(y){typeof y.runWhen=="function"&&y.runWhen(t)===!1||(s=s&&y.synchronous,n.unshift(y.fulfilled,y.rejected))});var a=[];this.interceptors.response.forEach(function(y){a.push(y.fulfilled,y.rejected)});var o;if(!s){var f=[je,void 0];for(Array.prototype.unshift.apply(f,n),f=f.concat(a),o=Promise.resolve(t);f.length;)o=o.then(f.shift(),f.shift());return o}for(var d=t;n.length;){var c=n.shift(),h=n.shift();try{d=c(d)}catch(u){h(u);break}}try{o=je(d)}catch(u){return Promise.reject(u)}for(;a.length;)o=o.then(a.shift(),a.shift());return o};N.prototype.getUri=function(e){e=z(this.defaults,e);var t=vt(e.baseURL,e.url);return mt(t,e.params,e.paramsSerializer)};ir.forEach(["delete","get","head","options"],function(e){N.prototype[e]=function(t,i){return this.request(z(i||{},{method:e,url:t,data:(i||{}).data}))}});ir.forEach(["post","put","patch"],function(e){function t(i){return function(s,a,o){return this.request(z(o||{},{method:e,headers:i?{"Content-Type":"multipart/form-data"}:{},url:s,data:a}))}}N.prototype[e]=t(),N.prototype[e+"Form"]=t(!0)});var Et=N,oe,Me;function yt(){if(Me)return oe;Me=1;var r=I();function e(t){if(typeof t!="function")throw new TypeError("executor must be a function.");var i;this.promise=new Promise(function(a){i=a});var n=this;this.promise.then(function(s){if(n._listeners){var a,o=n._listeners.length;for(a=0;a<o;a++)n._listeners[a](s);n._listeners=null}}),this.promise.then=function(s){var a,o=new Promise(function(f){n.subscribe(f),a=f}).then(s);return o.cancel=function(){n.unsubscribe(a)},o},t(function(a){n.reason||(n.reason=new r(a),i(n.reason))})}return e.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},e.prototype.subscribe=function(i){if(this.reason){i(this.reason);return}this._listeners?this._listeners.push(i):this._listeners=[i]},e.prototype.unsubscribe=function(i){if(this._listeners){var n=this._listeners.indexOf(i);n!==-1&&this._listeners.splice(n,1)}},e.source=function(){var i,n=new e(function(a){i=a});return{token:n,cancel:i}},oe=e,oe}var ue,He;function bt(){return He||(He=1,ue=function(e){return function(i){return e.apply(null,i)}}),ue}var fe,Ie;function Rt(){if(Ie)return fe;Ie=1;var r=m;return fe=function(t){return r.isObject(t)&&t.isAxiosError===!0},fe}var We=m,wt=ze,$=Et,gt=tr,Ot=Ee;function ar(r){var e=new $(r),t=wt($.prototype.request,e);return We.extend(t,$.prototype,e),We.extend(t,e),t.create=function(n){return ar(gt(r,n))},t}var v=ar(Ot);v.Axios=$;v.CanceledError=I();v.CancelToken=yt();v.isCancel=rr();v.VERSION=nr().version;v.toFormData=Ze;v.AxiosError=q;v.Cancel=v.CanceledError;v.all=function(e){return Promise.all(e)};v.spread=bt();v.isAxiosError=Rt();Er.exports=v;j.default=v;(function(r){r.exports=j})(vr);const St=mr(le);class or{constructor(e){O(this,"busyWorkers",new Set);O(this,"enabledGroups",new Set);O(this,"groups",new Map);O(this,"workerByIdMap",new Map);O(this,"timer",null);O(this,"config",{maxGroupsSize:50,maxWorkersSize:20,getIsNetworkOnline(){return!0},async getRequestHeaders(){return{}},debug(...e){console.log(...e)}});this.config={...this.config,...e??null}}stopTimer(){this.timer!=null&&(this.config.debug("*stop timer*"),clearInterval(this.timer),this.timer=null)}startTimer(){if(this.timer!=null)throw L(new Error("Timer already started"),k.ErrorCode.GenericUnexpectedHangfireError);this.config.debug("*start timer*"),this.timer=setInterval(()=>{this.config.debug("*tick*",{busyWorkers:this.busyWorkers.size,enabledGroups:this.enabledGroups.size,groups:this.groups}),this.enabledGroups.forEach(e=>{const t=this.groups.get(e);t&&t.forEach(i=>this.executeWorkerRequest(i))}),this.groups.size<1&&this.stopTimer()},5e3)}async executeWorkerRequest(e){const t=this.config.getIsNetworkOnline();!this.busyWorkers.has(e.workerId)&&t&&(this.busyWorkers.add(e.workerId),St({url:e.url,method:"get",headers:await this.config.getRequestHeaders()}).then(i=>{i&&!pr(i)&&(e.resolve(i),this.deleteWorker(e.groupId,e.workerId))}).catch(i=>{e.reject(i),this.deleteWorker(e.groupId,e.workerId)}))}deleteWorker(e,t){const i=this.groups.get(e);this.config.debug("*delete worker*",i.size,i),i.delete(t),this.workerByIdMap.delete(t),this.busyWorkers.delete(t),i.size<1&&(this.groups.delete(e),this.enabledGroups.delete(e),this.enabledGroups.size<1&&this.stopTimer())}createWorker(e,{workerId:t,url:i}){if(!this.groups.has(e)){if(this.groups.size>=this.config.maxGroupsSize){const s=L(new Error("Max number of Hangfire groups exceeded"),k.ErrorCode.GenericUnexpectedHangfireError,{count:this.groups.size});throw this.destroy(),s}this.groups.set(e,new Map)}const n=this.groups.get(e);return new Promise((s,a)=>{if(n.has(t))throw L(new Error("Duplicate Hangfire worker ID"),k.ErrorCode.GenericUnexpectedHangfireError);if(n.size>=this.config.maxWorkersSize){const f=L(new Error("Max number of Hangfire workers in group exceeded"),k.ErrorCode.GenericUnexpectedHangfireError,{groupId:e,count:n.size});throw a(f),this.destroy(),f}const o={workerId:t,groupId:e,url:i,resolve:s,reject:a};n.set(t,o),this.workerByIdMap.set(t,o),this.enabledGroups.has(e)||this.enabledGroups.add(e),this.timer==null&&this.enabledGroups.size>0&&this.startTimer()})}triggerWorker(e){this.config.debug("*triggerWorker*");const t=this.workerByIdMap.get(e);t&&this.executeWorkerRequest(t)}enableWorkers(e){this.config.debug("*enable*",e),this.enabledGroups.add(e),this.groups.has(e)&&this.timer==null&&this.startTimer()}disableWorkers(e){this.config.debug("*disable*",e),this.enabledGroups.delete(e),this.enabledGroups.size<1&&this.stopTimer()}destroy(){this.config.debug("*destroy*"),this.groups.clear(),this.stopTimer()}}function xt(r){return new or(r)}exports.HangfirePoller=or;exports.default=xt;
|
|
2
|
+
`),function(d){if(o=d.indexOf(":"),s=r.trim(d.substr(0,o)).toLowerCase(),a=r.trim(d.substr(o+1)),s){if(n[s]&&e.indexOf(s)>=0)return;s==="set-cookie"?n[s]=(n[s]?n[s]:[]).concat([a]):n[s]=n[s]?n[s]+", "+a:a}}),n},Q}var Y,Ae;function Qr(){if(Ae)return Y;Ae=1;var r=m;return Y=r.isStandardBrowserEnv()?function(){var t=/(msie|trident)/i.test(navigator.userAgent),i=document.createElement("a"),n;function s(a){var o=a;return t&&(i.setAttribute("href",o),o=i.href),i.setAttribute("href",o),{href:i.href,protocol:i.protocol?i.protocol.replace(/:$/,""):"",host:i.host,search:i.search?i.search.replace(/^\?/,""):"",hash:i.hash?i.hash.replace(/^#/,""):"",hostname:i.hostname,port:i.port,pathname:i.pathname.charAt(0)==="/"?i.pathname:"/"+i.pathname}}return n=s(window.location.href),function(o){var f=r.isString(o)?s(o):o;return f.protocol===n.protocol&&f.host===n.host}}():function(){return function(){return!0}}(),Y}var Z,Ce;function I(){if(Ce)return Z;Ce=1;var r=q,e=m;function t(i){r.call(this,i??"canceled",r.ERR_CANCELED),this.name="CanceledError"}return e.inherits(t,r,{__CANCEL__:!0}),Z=t,Z}var ee,Te;function Yr(){return Te||(Te=1,ee=function(e){var t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}),ee}var re,Pe;function _e(){if(Pe)return re;Pe=1;var r=m,e=Wr(),t=zr(),i=Ve,n=er,s=Kr(),a=Qr(),o=Ye,f=q,d=I(),c=Yr();return re=function(u){return new Promise(function(ur,x){var D=u.data,U=u.headers,B=u.responseType,A;function be(){u.cancelToken&&u.cancelToken.unsubscribe(A),u.signal&&u.signal.removeEventListener("abort",A)}r.isFormData(D)&&r.isStandardBrowserEnv()&&delete U["Content-Type"];var l=new XMLHttpRequest;if(u.auth){var fr=u.auth.username||"",lr=u.auth.password?unescape(encodeURIComponent(u.auth.password)):"";U.Authorization="Basic "+btoa(fr+":"+lr)}var G=n(u.baseURL,u.url);l.open(u.method.toUpperCase(),i(G,u.params,u.paramsSerializer),!0),l.timeout=u.timeout;function Re(){if(l){var b="getAllResponseHeaders"in l?s(l.getAllResponseHeaders()):null,C=!B||B==="text"||B==="json"?l.responseText:l.response,g={data:C,status:l.status,statusText:l.statusText,headers:b,config:u,request:l};e(function(V){ur(V),be()},function(V){x(V),be()},g),l=null}}if("onloadend"in l?l.onloadend=Re:l.onreadystatechange=function(){!l||l.readyState!==4||l.status===0&&!(l.responseURL&&l.responseURL.indexOf("file:")===0)||setTimeout(Re)},l.onabort=function(){l&&(x(new f("Request aborted",f.ECONNABORTED,u,l)),l=null)},l.onerror=function(){x(new f("Network Error",f.ERR_NETWORK,u,l,l)),l=null},l.ontimeout=function(){var C=u.timeout?"timeout of "+u.timeout+"ms exceeded":"timeout exceeded",g=u.transitional||o;u.timeoutErrorMessage&&(C=u.timeoutErrorMessage),x(new f(C,g.clarifyTimeoutError?f.ETIMEDOUT:f.ECONNABORTED,u,l)),l=null},r.isStandardBrowserEnv()){var we=(u.withCredentials||a(G))&&u.xsrfCookieName?t.read(u.xsrfCookieName):void 0;we&&(U[u.xsrfHeaderName]=we)}"setRequestHeader"in l&&r.forEach(U,function(C,g){typeof D>"u"&&g.toLowerCase()==="content-type"?delete U[g]:l.setRequestHeader(g,C)}),r.isUndefined(u.withCredentials)||(l.withCredentials=!!u.withCredentials),B&&B!=="json"&&(l.responseType=u.responseType),typeof u.onDownloadProgress=="function"&&l.addEventListener("progress",u.onDownloadProgress),typeof u.onUploadProgress=="function"&&l.upload&&l.upload.addEventListener("progress",u.onUploadProgress),(u.cancelToken||u.signal)&&(A=function(b){l&&(x(!b||b&&b.type?new d:b),l.abort(),l=null)},u.cancelToken&&u.cancelToken.subscribe(A),u.signal&&(u.signal.aborted?A():u.signal.addEventListener("abort",A))),D||(D=null);var J=c(G);if(J&&["http","https","file"].indexOf(J)===-1){x(new f("Unsupported protocol "+J+":",f.ERR_BAD_REQUEST,u));return}l.send(D)})},re}var te,Ne;function Zr(){return Ne||(Ne=1,te=null),te}var p=m,qe=Hr,De=q,et=Ye,rt=Ze,tt={"Content-Type":"application/x-www-form-urlencoded"};function Ue(r,e){!p.isUndefined(r)&&p.isUndefined(r["Content-Type"])&&(r["Content-Type"]=e)}function nt(){var r;return(typeof XMLHttpRequest<"u"||typeof process<"u"&&Object.prototype.toString.call(process)==="[object process]")&&(r=_e()),r}function it(r,e,t){if(p.isString(r))try{return(e||JSON.parse)(r),p.trim(r)}catch(i){if(i.name!=="SyntaxError")throw i}return(t||JSON.stringify)(r)}var W={transitional:et,adapter:nt(),transformRequest:[function(e,t){if(qe(t,"Accept"),qe(t,"Content-Type"),p.isFormData(e)||p.isArrayBuffer(e)||p.isBuffer(e)||p.isStream(e)||p.isFile(e)||p.isBlob(e))return e;if(p.isArrayBufferView(e))return e.buffer;if(p.isURLSearchParams(e))return Ue(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString();var i=p.isObject(e),n=t&&t["Content-Type"],s;if((s=p.isFileList(e))||i&&n==="multipart/form-data"){var a=this.env&&this.env.FormData;return rt(s?{"files[]":e}:e,a&&new a)}else if(i||n==="application/json")return Ue(t,"application/json"),it(e);return e}],transformResponse:[function(e){var t=this.transitional||W.transitional,i=t&&t.silentJSONParsing,n=t&&t.forcedJSONParsing,s=!i&&this.responseType==="json";if(s||n&&p.isString(e)&&e.length)try{return JSON.parse(e)}catch(a){if(s)throw a.name==="SyntaxError"?De.from(a,De.ERR_BAD_RESPONSE,this,null,this.response):a}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Zr()},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};p.forEach(["delete","get","head"],function(e){W.headers[e]={}});p.forEach(["post","put","patch"],function(e){W.headers[e]=p.merge(tt)});var Ee=W,st=m,at=Ee,ot=function(e,t,i){var n=this||at;return st.forEach(i,function(a){e=a.call(n,e,t)}),e},ne,Be;function rr(){return Be||(Be=1,ne=function(e){return!!(e&&e.__CANCEL__)}),ne}var ke=m,ie=ot,ut=rr(),ft=Ee,lt=I();function se(r){if(r.cancelToken&&r.cancelToken.throwIfRequested(),r.signal&&r.signal.aborted)throw new lt}var ct=function(e){se(e),e.headers=e.headers||{},e.data=ie.call(e,e.data,e.headers,e.transformRequest),e.headers=ke.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),ke.forEach(["delete","get","head","post","put","patch","common"],function(n){delete e.headers[n]});var t=e.adapter||ft.adapter;return t(e).then(function(n){return se(e),n.data=ie.call(e,n.data,n.headers,e.transformResponse),n},function(n){return ut(n)||(se(e),n&&n.response&&(n.response.data=ie.call(e,n.response.data,n.response.headers,e.transformResponse))),Promise.reject(n)})},E=m,tr=function(e,t){t=t||{};var i={};function n(c,h){return E.isPlainObject(c)&&E.isPlainObject(h)?E.merge(c,h):E.isPlainObject(h)?E.merge({},h):E.isArray(h)?h.slice():h}function s(c){if(E.isUndefined(t[c])){if(!E.isUndefined(e[c]))return n(void 0,e[c])}else return n(e[c],t[c])}function a(c){if(!E.isUndefined(t[c]))return n(void 0,t[c])}function o(c){if(E.isUndefined(t[c])){if(!E.isUndefined(e[c]))return n(void 0,e[c])}else return n(void 0,t[c])}function f(c){if(c in t)return n(e[c],t[c]);if(c in e)return n(void 0,e[c])}var d={url:a,method:a,data:a,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:f};return E.forEach(Object.keys(e).concat(Object.keys(t)),function(h){var u=d[h]||s,y=u(h);E.isUndefined(y)&&u!==f||(i[h]=y)}),i},ae,Le;function nr(){return Le||(Le=1,ae={version:"0.27.2"}),ae}var dt=nr().version,w=q,ye={};["object","boolean","number","function","string","symbol"].forEach(function(r,e){ye[r]=function(i){return typeof i===r||"a"+(e<1?"n ":" ")+r}});var Fe={};ye.transitional=function(e,t,i){function n(s,a){return"[Axios v"+dt+"] Transitional option '"+s+"'"+a+(i?". "+i:"")}return function(s,a,o){if(e===!1)throw new w(n(a," has been removed"+(t?" in "+t:"")),w.ERR_DEPRECATED);return t&&!Fe[a]&&(Fe[a]=!0,console.warn(n(a," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(s,a,o):!0}};function ht(r,e,t){if(typeof r!="object")throw new w("options must be an object",w.ERR_BAD_OPTION_VALUE);for(var i=Object.keys(r),n=i.length;n-- >0;){var s=i[n],a=e[s];if(a){var o=r[s],f=o===void 0||a(o,s,r);if(f!==!0)throw new w("option "+s+" must be "+f,w.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new w("Unknown option "+s,w.ERR_BAD_OPTION)}}var pt={assertOptions:ht,validators:ye},ir=m,mt=Ve,$e=jr,je=ct,z=tr,vt=er,sr=pt,P=sr.validators;function N(r){this.defaults=r,this.interceptors={request:new $e,response:new $e}}N.prototype.request=function(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=z(this.defaults,t),t.method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var i=t.transitional;i!==void 0&&sr.assertOptions(i,{silentJSONParsing:P.transitional(P.boolean),forcedJSONParsing:P.transitional(P.boolean),clarifyTimeoutError:P.transitional(P.boolean)},!1);var n=[],s=!0;this.interceptors.request.forEach(function(y){typeof y.runWhen=="function"&&y.runWhen(t)===!1||(s=s&&y.synchronous,n.unshift(y.fulfilled,y.rejected))});var a=[];this.interceptors.response.forEach(function(y){a.push(y.fulfilled,y.rejected)});var o;if(!s){var f=[je,void 0];for(Array.prototype.unshift.apply(f,n),f=f.concat(a),o=Promise.resolve(t);f.length;)o=o.then(f.shift(),f.shift());return o}for(var d=t;n.length;){var c=n.shift(),h=n.shift();try{d=c(d)}catch(u){h(u);break}}try{o=je(d)}catch(u){return Promise.reject(u)}for(;a.length;)o=o.then(a.shift(),a.shift());return o};N.prototype.getUri=function(e){e=z(this.defaults,e);var t=vt(e.baseURL,e.url);return mt(t,e.params,e.paramsSerializer)};ir.forEach(["delete","get","head","options"],function(e){N.prototype[e]=function(t,i){return this.request(z(i||{},{method:e,url:t,data:(i||{}).data}))}});ir.forEach(["post","put","patch"],function(e){function t(i){return function(s,a,o){return this.request(z(o||{},{method:e,headers:i?{"Content-Type":"multipart/form-data"}:{},url:s,data:a}))}}N.prototype[e]=t(),N.prototype[e+"Form"]=t(!0)});var Et=N,oe,Me;function yt(){if(Me)return oe;Me=1;var r=I();function e(t){if(typeof t!="function")throw new TypeError("executor must be a function.");var i;this.promise=new Promise(function(a){i=a});var n=this;this.promise.then(function(s){if(n._listeners){var a,o=n._listeners.length;for(a=0;a<o;a++)n._listeners[a](s);n._listeners=null}}),this.promise.then=function(s){var a,o=new Promise(function(f){n.subscribe(f),a=f}).then(s);return o.cancel=function(){n.unsubscribe(a)},o},t(function(a){n.reason||(n.reason=new r(a),i(n.reason))})}return e.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},e.prototype.subscribe=function(i){if(this.reason){i(this.reason);return}this._listeners?this._listeners.push(i):this._listeners=[i]},e.prototype.unsubscribe=function(i){if(this._listeners){var n=this._listeners.indexOf(i);n!==-1&&this._listeners.splice(n,1)}},e.source=function(){var i,n=new e(function(a){i=a});return{token:n,cancel:i}},oe=e,oe}var ue,He;function bt(){return He||(He=1,ue=function(e){return function(i){return e.apply(null,i)}}),ue}var fe,Ie;function Rt(){if(Ie)return fe;Ie=1;var r=m;return fe=function(t){return r.isObject(t)&&t.isAxiosError===!0},fe}var We=m,wt=ze,$=Et,gt=tr,Ot=Ee;function ar(r){var e=new $(r),t=wt($.prototype.request,e);return We.extend(t,$.prototype,e),We.extend(t,e),t.create=function(n){return ar(gt(r,n))},t}var v=ar(Ot);v.Axios=$;v.CanceledError=I();v.CancelToken=yt();v.isCancel=rr();v.VERSION=nr().version;v.toFormData=Ze;v.AxiosError=q;v.Cancel=v.CanceledError;v.all=function(e){return Promise.all(e)};v.spread=bt();v.isAxiosError=Rt();Er.exports=v;j.default=v;(function(r){r.exports=j})(vr);const St=mr(le);class or{constructor(e){O(this,"busyWorkers",new Set);O(this,"enabledGroups",new Set);O(this,"groups",new Map);O(this,"workerByIdMap",new Map);O(this,"timer",null);O(this,"config",{maxGroupsSize:50,maxWorkersSize:20,getIsNetworkOnline(){return!0},async getRequestHeaders(){return{}},debug(...e){console.log(...e)}});this.config={...this.config,...e??null}}stopTimer(){this.timer!=null&&(this.config.debug("*stop timer*"),clearInterval(this.timer),this.timer=null)}startTimer(){if(this.timer!=null)throw L(new Error("Timer already started"),k.ErrorCode.GenericUnexpectedHangfireError);this.config.debug("*start timer*"),this.timer=setInterval(()=>{this.config.debug("*tick*",{busyWorkers:this.busyWorkers.size,enabledGroups:this.enabledGroups.size,groups:this.groups}),this.enabledGroups.forEach(e=>{const t=this.groups.get(e);t&&t.forEach(i=>this.executeWorkerRequest(i))}),this.groups.size<1&&this.stopTimer()},5e3)}async executeWorkerRequest(e){const t=this.config.getIsNetworkOnline();!this.busyWorkers.has(e.workerId)&&t&&(this.busyWorkers.add(e.workerId),St({url:e.url,method:"get",headers:await this.config.getRequestHeaders()}).then(i=>{i&&!pr(i)?(e.resolve(i),this.deleteWorker(e.groupId,e.workerId)):this.busyWorkers.delete(e.workerId)}).catch(i=>{e.reject(i),this.deleteWorker(e.groupId,e.workerId)}))}deleteWorker(e,t){const i=this.groups.get(e);this.config.debug("*delete worker*",i.size,i),i.delete(t),this.workerByIdMap.delete(t),this.busyWorkers.delete(t),i.size<1&&(this.groups.delete(e),this.enabledGroups.delete(e),this.enabledGroups.size<1&&this.stopTimer())}createWorker(e,{workerId:t,url:i}){if(!this.groups.has(e)){if(this.groups.size>=this.config.maxGroupsSize){const s=L(new Error("Max number of Hangfire groups exceeded"),k.ErrorCode.GenericUnexpectedHangfireError,{count:this.groups.size});throw this.destroy(),s}this.groups.set(e,new Map)}const n=this.groups.get(e);return new Promise((s,a)=>{if(n.has(t))throw L(new Error("Duplicate Hangfire worker ID"),k.ErrorCode.GenericUnexpectedHangfireError);if(n.size>=this.config.maxWorkersSize){const f=L(new Error("Max number of Hangfire workers in group exceeded"),k.ErrorCode.GenericUnexpectedHangfireError,{groupId:e,count:n.size});throw a(f),this.destroy(),f}const o={workerId:t,groupId:e,url:i,resolve:s,reject:a};n.set(t,o),this.workerByIdMap.set(t,o),this.enabledGroups.has(e)||this.enabledGroups.add(e),this.timer==null&&this.enabledGroups.size>0&&this.startTimer()})}triggerWorker(e){this.config.debug("*triggerWorker*");const t=this.workerByIdMap.get(e);t&&this.executeWorkerRequest(t)}enableWorkers(e){this.config.debug("*enable*",e),this.enabledGroups.add(e),this.groups.has(e)&&this.timer==null&&this.startTimer()}disableWorkers(e){this.config.debug("*disable*",e),this.enabledGroups.delete(e),this.enabledGroups.size<1&&this.stopTimer()}destroy(){this.config.debug("*destroy*"),this.groups.clear(),this.stopTimer()}}function xt(r){return new or(r)}exports.HangfirePoller=or;exports.default=xt;
|
|
@@ -41,11 +41,11 @@ function x(r) {
|
|
|
41
41
|
function pe(r) {
|
|
42
42
|
return Array.isArray(r);
|
|
43
43
|
}
|
|
44
|
-
function
|
|
44
|
+
function I(r) {
|
|
45
45
|
return typeof r > "u";
|
|
46
46
|
}
|
|
47
47
|
function yr(r) {
|
|
48
|
-
return r !== null && !
|
|
48
|
+
return r !== null && !I(r) && r.constructor !== null && !I(r.constructor) && typeof r.constructor.isBuffer == "function" && r.constructor.isBuffer(r);
|
|
49
49
|
}
|
|
50
50
|
var Ge = x("ArrayBuffer");
|
|
51
51
|
function br(r) {
|
|
@@ -133,7 +133,7 @@ function kr(r) {
|
|
|
133
133
|
if (!r)
|
|
134
134
|
return null;
|
|
135
135
|
var e = r.length;
|
|
136
|
-
if (
|
|
136
|
+
if (I(e))
|
|
137
137
|
return null;
|
|
138
138
|
for (var t = new Array(e); e-- > 0; )
|
|
139
139
|
t[e] = r[e];
|
|
@@ -153,7 +153,7 @@ var Lr = function(r) {
|
|
|
153
153
|
isNumber: wr,
|
|
154
154
|
isObject: Je,
|
|
155
155
|
isPlainObject: F,
|
|
156
|
-
isUndefined:
|
|
156
|
+
isUndefined: I,
|
|
157
157
|
isDate: gr,
|
|
158
158
|
isFile: Or,
|
|
159
159
|
isBlob: xr,
|
|
@@ -200,10 +200,10 @@ var Ve = function(e, t, i) {
|
|
|
200
200
|
}
|
|
201
201
|
return e;
|
|
202
202
|
}, Fr = m;
|
|
203
|
-
function
|
|
203
|
+
function H() {
|
|
204
204
|
this.handlers = [];
|
|
205
205
|
}
|
|
206
|
-
|
|
206
|
+
H.prototype.use = function(e, t, i) {
|
|
207
207
|
return this.handlers.push({
|
|
208
208
|
fulfilled: e,
|
|
209
209
|
rejected: t,
|
|
@@ -211,15 +211,15 @@ I.prototype.use = function(e, t, i) {
|
|
|
211
211
|
runWhen: i ? i.runWhen : null
|
|
212
212
|
}), this.handlers.length - 1;
|
|
213
213
|
};
|
|
214
|
-
|
|
214
|
+
H.prototype.eject = function(e) {
|
|
215
215
|
this.handlers[e] && (this.handlers[e] = null);
|
|
216
216
|
};
|
|
217
|
-
|
|
217
|
+
H.prototype.forEach = function(e) {
|
|
218
218
|
Fr.forEach(this.handlers, function(i) {
|
|
219
219
|
i !== null && e(i);
|
|
220
220
|
});
|
|
221
221
|
};
|
|
222
|
-
var $r =
|
|
222
|
+
var $r = H, jr = m, Ir = function(e, t) {
|
|
223
223
|
jr.forEach(e, function(n, s) {
|
|
224
224
|
s !== t && s.toUpperCase() === t.toUpperCase() && (e[t] = n, delete e[s]);
|
|
225
225
|
});
|
|
@@ -272,7 +272,7 @@ var D = N, Ye = {
|
|
|
272
272
|
forcedJSONParsing: !0,
|
|
273
273
|
clarifyTimeoutError: !1
|
|
274
274
|
}, R = m;
|
|
275
|
-
function
|
|
275
|
+
function Hr(r, e) {
|
|
276
276
|
e = e || new FormData();
|
|
277
277
|
var t = [];
|
|
278
278
|
function i(s) {
|
|
@@ -303,7 +303,7 @@ function Ir(r, e) {
|
|
|
303
303
|
}
|
|
304
304
|
return n(r), e;
|
|
305
305
|
}
|
|
306
|
-
var Ze =
|
|
306
|
+
var Ze = Hr, X, Oe;
|
|
307
307
|
function Mr() {
|
|
308
308
|
if (Oe)
|
|
309
309
|
return X;
|
|
@@ -518,7 +518,7 @@ var te, _e;
|
|
|
518
518
|
function Yr() {
|
|
519
519
|
return _e || (_e = 1, te = null), te;
|
|
520
520
|
}
|
|
521
|
-
var p = m, De =
|
|
521
|
+
var p = m, De = Ir, Ue = D, Zr = Ye, et = Ze, rt = {
|
|
522
522
|
"Content-Type": "application/x-www-form-urlencoded"
|
|
523
523
|
};
|
|
524
524
|
function qe(r, e) {
|
|
@@ -827,11 +827,11 @@ ir.forEach(["post", "put", "patch"], function(e) {
|
|
|
827
827
|
}
|
|
828
828
|
_.prototype[e] = t(), _.prototype[e + "Form"] = t(!0);
|
|
829
829
|
});
|
|
830
|
-
var vt = _, oe,
|
|
830
|
+
var vt = _, oe, Ie;
|
|
831
831
|
function Et() {
|
|
832
|
-
if (
|
|
832
|
+
if (Ie)
|
|
833
833
|
return oe;
|
|
834
|
-
|
|
834
|
+
Ie = 1;
|
|
835
835
|
var r = M();
|
|
836
836
|
function e(t) {
|
|
837
837
|
if (typeof t != "function")
|
|
@@ -883,9 +883,9 @@ function Et() {
|
|
|
883
883
|
};
|
|
884
884
|
}, oe = e, oe;
|
|
885
885
|
}
|
|
886
|
-
var ue,
|
|
886
|
+
var ue, He;
|
|
887
887
|
function yt() {
|
|
888
|
-
return
|
|
888
|
+
return He || (He = 1, ue = function(e) {
|
|
889
889
|
return function(i) {
|
|
890
890
|
return e.apply(null, i);
|
|
891
891
|
};
|
|
@@ -980,7 +980,7 @@ class xt {
|
|
|
980
980
|
method: "get",
|
|
981
981
|
headers: await this.config.getRequestHeaders()
|
|
982
982
|
}).then((i) => {
|
|
983
|
-
i && !hr(i)
|
|
983
|
+
i && !hr(i) ? (e.resolve(i), this.deleteWorker(e.groupId, e.workerId)) : this.busyWorkers.delete(e.workerId);
|
|
984
984
|
}).catch((i) => {
|
|
985
985
|
e.reject(i), this.deleteWorker(e.groupId, e.workerId);
|
|
986
986
|
}));
|