@3kles/3kles-corebe
Version:
3KLES Core BackEnd
2 lines • 775 kB
JavaScript
/*! For license information please see index.js.LICENSE.txt */
(()=>{var e={1902(e,t,n){"use strict";n.r(t),n.d(t,{DiagConsoleLogger:()=>k,DiagLogLevel:()=>f,INVALID_SPANID:()=>te,INVALID_SPAN_CONTEXT:()=>re,INVALID_TRACEID:()=>ne,ProxyTracer:()=>Se,ProxyTracerProvider:()=>je,ROOT_CONTEXT:()=>O,SamplingDecision:()=>be,SpanKind:()=>ye,SpanStatusCode:()=>xe,TraceFlags:()=>W,ValueType:()=>S,baggageEntryMetadataFromString:()=>w,context:()=>Re,createContextKey:()=>E,createNoopMeter:()=>K,createTraceState:()=>Ne,default:()=>Xe,defaultTextMapGetter:()=>J,defaultTextMapSetter:()=>X,diag:()=>Le,isSpanContextValid:()=>ve,isValidSpanId:()=>he,isValidTraceId:()=>me,metrics:()=>Me,propagation:()=>Ke,trace:()=>Je});var r="object"==typeof globalThis?globalThis:global,i="1.9.0",o=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/,a=function(e){var t=new Set([e]),n=new Set,r=e.match(o);if(!r)return function(){return!1};var i=+r[1],a=+r[2],s=+r[3];if(null!=r[4])return function(t){return t===e};function c(e){return n.add(e),!1}function p(e){return t.add(e),!0}return function(e){if(t.has(e))return!0;if(n.has(e))return!1;var r=e.match(o);if(!r)return c(e);var l=+r[1],u=+r[2],d=+r[3];return null!=r[4]||i!==l?c(e):0===i?a===u&&s<=d?p(e):c(e):a<=u?p(e):c(e)}}(i),s=i.split(".")[0],c=Symbol.for("opentelemetry.js.api."+s),p=r;function l(e,t,n,r){var o;void 0===r&&(r=!1);var a=p[c]=null!==(o=p[c])&&void 0!==o?o:{version:i};if(!r&&a[e]){var s=new Error("@opentelemetry/api: Attempted duplicate registration of API: "+e);return n.error(s.stack||s.message),!1}return a.version!==i?(s=new Error("@opentelemetry/api: Registration of version v"+a.version+" for "+e+" does not match previously registered API v"+i),n.error(s.stack||s.message),!1):(a[e]=t,n.debug("@opentelemetry/api: Registered a global for "+e+" v"+i+"."),!0)}function u(e){var t,n,r=null===(t=p[c])||void 0===t?void 0:t.version;if(r&&a(r))return null===(n=p[c])||void 0===n?void 0:n[e]}function d(e,t){t.debug("@opentelemetry/api: Unregistering a global for "+e+" v"+i+".");var n=p[c];n&&delete n[e]}var f,m=function(){function e(e){this._namespace=e.namespace||"DiagComponentLogger"}return e.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return h("debug",this._namespace,e)},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return h("error",this._namespace,e)},e.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return h("info",this._namespace,e)},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return h("warn",this._namespace,e)},e.prototype.verbose=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return h("verbose",this._namespace,e)},e}();function h(e,t,n){var r=u("diag");if(r)return n.unshift(t),r[e].apply(r,function(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}(n),!1))}!function(e){e[e.NONE=0]="NONE",e[e.ERROR=30]="ERROR",e[e.WARN=50]="WARN",e[e.INFO=60]="INFO",e[e.DEBUG=70]="DEBUG",e[e.VERBOSE=80]="VERBOSE",e[e.ALL=9999]="ALL"}(f||(f={}));var v=function(){function e(){function e(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=u("diag");if(r)return r[e].apply(r,function(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}(t),!1))}}var t=this;t.setLogger=function(e,n){var r,i,o;if(void 0===n&&(n={logLevel:f.INFO}),e===t){var a=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");return t.error(null!==(r=a.stack)&&void 0!==r?r:a.message),!1}"number"==typeof n&&(n={logLevel:n});var s=u("diag"),c=function(e,t){function n(n,r){var i=t[n];return"function"==typeof i&&e>=r?i.bind(t):function(){}}return e<f.NONE?e=f.NONE:e>f.ALL&&(e=f.ALL),t=t||{},{error:n("error",f.ERROR),warn:n("warn",f.WARN),info:n("info",f.INFO),debug:n("debug",f.DEBUG),verbose:n("verbose",f.VERBOSE)}}(null!==(i=n.logLevel)&&void 0!==i?i:f.INFO,e);if(s&&!n.suppressOverrideMessage){var p=null!==(o=(new Error).stack)&&void 0!==o?o:"<failed to generate stacktrace>";s.warn("Current logger will be overwritten from "+p),c.warn("Current logger will overwrite one already registered from "+p)}return l("diag",c,t,!0)},t.disable=function(){d("diag",t)},t.createComponentLogger=function(e){return new m(e)},t.verbose=e("verbose"),t.debug=e("debug"),t.info=e("info"),t.warn=e("warn"),t.error=e("error")}return e.instance=function(){return this._instance||(this._instance=new e),this._instance},e}(),g=function(){function e(e){this._entries=e?new Map(e):new Map}return e.prototype.getEntry=function(e){var t=this._entries.get(e);if(t)return Object.assign({},t)},e.prototype.getAllEntries=function(){return Array.from(this._entries.entries()).map(function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}(e,2);return[t[0],t[1]]})},e.prototype.setEntry=function(t,n){var r=new e(this._entries);return r._entries.set(t,n),r},e.prototype.removeEntry=function(t){var n=new e(this._entries);return n._entries.delete(t),n},e.prototype.removeEntries=function(){for(var t,n,r=[],i=0;i<arguments.length;i++)r[i]=arguments[i];var o=new e(this._entries);try{for(var a=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(r),s=a.next();!s.done;s=a.next()){var c=s.value;o._entries.delete(c)}}catch(e){t={error:e}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}return o},e.prototype.clear=function(){return new e},e}(),b=Symbol("BaggageEntryMetadata"),y=v.instance();function x(e){return void 0===e&&(e={}),new g(new Map(Object.entries(e)))}function w(e){return"string"!=typeof e&&(y.error("Cannot create baggage metadata from unknown type: "+typeof e),e=""),{__TYPE__:b,toString:function(){return e}}}function E(e){return Symbol.for(e)}var _,S,O=new function e(t){var n=this;n._currentContext=t?new Map(t):new Map,n.getValue=function(e){return n._currentContext.get(e)},n.setValue=function(t,r){var i=new e(n._currentContext);return i._currentContext.set(t,r),i},n.deleteValue=function(t){var r=new e(n._currentContext);return r._currentContext.delete(t),r}},j=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}],k=function(){function e(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];if(console){var r=console[e];if("function"!=typeof r&&(r=console.log),"function"==typeof r)return r.apply(console,t)}}}for(var t=0;t<j.length;t++)this[j[t].n]=e(j[t].c)},A=(_=function(e,t){return _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},_(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}_(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),T=function(){function e(){}return e.prototype.createGauge=function(e,t){return F},e.prototype.createHistogram=function(e,t){return z},e.prototype.createCounter=function(e,t){return q},e.prototype.createUpDownCounter=function(e,t){return U},e.prototype.createObservableGauge=function(e,t){return H},e.prototype.createObservableCounter=function(e,t){return G},e.prototype.createObservableUpDownCounter=function(e,t){return V},e.prototype.addBatchObservableCallback=function(e,t){},e.prototype.removeBatchObservableCallback=function(e){},e}(),C=function(){},P=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return A(t,e),t.prototype.add=function(e,t){},t}(C),N=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return A(t,e),t.prototype.add=function(e,t){},t}(C),R=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return A(t,e),t.prototype.record=function(e,t){},t}(C),L=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return A(t,e),t.prototype.record=function(e,t){},t}(C),I=function(){function e(){}return e.prototype.addCallback=function(e){},e.prototype.removeCallback=function(e){},e}(),$=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return A(t,e),t}(I),M=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return A(t,e),t}(I),B=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return A(t,e),t}(I),D=new T,q=new P,F=new R,z=new L,U=new N,G=new $,H=new M,V=new B;function K(){return D}!function(e){e[e.INT=0]="INT",e[e.DOUBLE=1]="DOUBLE"}(S||(S={}));var W,J={get:function(e,t){if(null!=e)return e[t]},keys:function(e){return null==e?[]:Object.keys(e)}},X={set:function(e,t,n){null!=e&&(e[t]=n)}},Y=function(){function e(){}return e.prototype.active=function(){return O},e.prototype.with=function(e,t,n){for(var r=[],i=3;i<arguments.length;i++)r[i-3]=arguments[i];return t.call.apply(t,function(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}([n],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}(r),!1))},e.prototype.bind=function(e,t){return t},e.prototype.enable=function(){return this},e.prototype.disable=function(){return this},e}(),Z="context",Q=new Y,ee=function(){function e(){}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalContextManager=function(e){return l(Z,e,v.instance())},e.prototype.active=function(){return this._getContextManager().active()},e.prototype.with=function(e,t,n){for(var r,i=[],o=3;o<arguments.length;o++)i[o-3]=arguments[o];return(r=this._getContextManager()).with.apply(r,function(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}([e,t,n],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}(i),!1))},e.prototype.bind=function(e,t){return this._getContextManager().bind(e,t)},e.prototype._getContextManager=function(){return u(Z)||Q},e.prototype.disable=function(){this._getContextManager().disable(),d(Z,v.instance())},e}();!function(e){e[e.NONE=0]="NONE",e[e.SAMPLED=1]="SAMPLED"}(W||(W={}));var te="0000000000000000",ne="00000000000000000000000000000000",re={traceId:ne,spanId:te,traceFlags:W.NONE},ie=function(){function e(e){void 0===e&&(e=re),this._spanContext=e}return e.prototype.spanContext=function(){return this._spanContext},e.prototype.setAttribute=function(e,t){return this},e.prototype.setAttributes=function(e){return this},e.prototype.addEvent=function(e,t){return this},e.prototype.addLink=function(e){return this},e.prototype.addLinks=function(e){return this},e.prototype.setStatus=function(e){return this},e.prototype.updateName=function(e){return this},e.prototype.end=function(e){},e.prototype.isRecording=function(){return!1},e.prototype.recordException=function(e,t){},e}(),oe=E("OpenTelemetry Context Key SPAN");function ae(e){return e.getValue(oe)||void 0}function se(){return ae(ee.getInstance().active())}function ce(e,t){return e.setValue(oe,t)}function pe(e){return e.deleteValue(oe)}function le(e,t){return ce(e,new ie(t))}function ue(e){var t;return null===(t=ae(e))||void 0===t?void 0:t.spanContext()}var de=/^([0-9a-f]{32})$/i,fe=/^[0-9a-f]{16}$/i;function me(e){return de.test(e)&&e!==ne}function he(e){return fe.test(e)&&e!==te}function ve(e){return me(e.traceId)&&he(e.spanId)}function ge(e){return new ie(e)}var be,ye,xe,we=ee.getInstance(),Ee=function(){function e(){}return e.prototype.startSpan=function(e,t,n){if(void 0===n&&(n=we.active()),Boolean(null==t?void 0:t.root))return new ie;var r,i=n&&ue(n);return"object"==typeof(r=i)&&"string"==typeof r.spanId&&"string"==typeof r.traceId&&"number"==typeof r.traceFlags&&ve(i)?new ie(i):new ie},e.prototype.startActiveSpan=function(e,t,n,r){var i,o,a;if(!(arguments.length<2)){2===arguments.length?a=t:3===arguments.length?(i=t,a=n):(i=t,o=n,a=r);var s=null!=o?o:we.active(),c=this.startSpan(e,i,s),p=ce(s,c);return we.with(p,a,void 0,c)}},e}(),_e=new Ee,Se=function(){function e(e,t,n,r){this._provider=e,this.name=t,this.version=n,this.options=r}return e.prototype.startSpan=function(e,t,n){return this._getTracer().startSpan(e,t,n)},e.prototype.startActiveSpan=function(e,t,n,r){var i=this._getTracer();return Reflect.apply(i.startActiveSpan,i,arguments)},e.prototype._getTracer=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateTracer(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):_e},e}(),Oe=new(function(){function e(){}return e.prototype.getTracer=function(e,t,n){return new Ee},e}()),je=function(){function e(){}return e.prototype.getTracer=function(e,t,n){var r;return null!==(r=this.getDelegateTracer(e,t,n))&&void 0!==r?r:new Se(this,e,t,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:Oe},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateTracer=function(e,t,n){var r;return null===(r=this._delegate)||void 0===r?void 0:r.getTracer(e,t,n)},e}();!function(e){e[e.NOT_RECORD=0]="NOT_RECORD",e[e.RECORD=1]="RECORD",e[e.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"}(be||(be={})),function(e){e[e.INTERNAL=0]="INTERNAL",e[e.SERVER=1]="SERVER",e[e.CLIENT=2]="CLIENT",e[e.PRODUCER=3]="PRODUCER",e[e.CONSUMER=4]="CONSUMER"}(ye||(ye={})),function(e){e[e.UNSET=0]="UNSET",e[e.OK=1]="OK",e[e.ERROR=2]="ERROR"}(xe||(xe={}));var ke="[_0-9a-z-*/]",Ae=new RegExp("^(?:[a-z]"+ke+"{0,255}|[a-z0-9]"+ke+"{0,240}@[a-z]"+ke+"{0,13})$"),Te=/^[ -~]{0,255}[!-~]$/,Ce=/,|=/,Pe=function(){function e(e){this._internalState=new Map,e&&this._parse(e)}return e.prototype.set=function(e,t){var n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n},e.prototype.unset=function(e){var t=this._clone();return t._internalState.delete(e),t},e.prototype.get=function(e){return this._internalState.get(e)},e.prototype.serialize=function(){var e=this;return this._keys().reduce(function(t,n){return t.push(n+"="+e.get(n)),t},[]).join(",")},e.prototype._parse=function(e){e.length>512||(this._internalState=e.split(",").reverse().reduce(function(e,t){var n=t.trim(),r=n.indexOf("=");if(-1!==r){var i=n.slice(0,r),o=n.slice(r+1,t.length);(function(e){return Ae.test(e)})(i)&&function(e){return Te.test(e)&&!Ce.test(e)}(o)&&e.set(i,o)}return e},new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))},e.prototype._keys=function(){return Array.from(this._internalState.keys()).reverse()},e.prototype._clone=function(){var t=new e;return t._internalState=new Map(this._internalState),t},e}();function Ne(e){return new Pe(e)}var Re=ee.getInstance(),Le=v.instance(),Ie=new(function(){function e(){}return e.prototype.getMeter=function(e,t,n){return D},e}()),$e="metrics",Me=function(){function e(){}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalMeterProvider=function(e){return l($e,e,v.instance())},e.prototype.getMeterProvider=function(){return u($e)||Ie},e.prototype.getMeter=function(e,t,n){return this.getMeterProvider().getMeter(e,t,n)},e.prototype.disable=function(){d($e,v.instance())},e}().getInstance(),Be=function(){function e(){}return e.prototype.inject=function(e,t){},e.prototype.extract=function(e,t){return e},e.prototype.fields=function(){return[]},e}(),De=E("OpenTelemetry Baggage Key");function qe(e){return e.getValue(De)||void 0}function Fe(){return qe(ee.getInstance().active())}function ze(e,t){return e.setValue(De,t)}function Ue(e){return e.deleteValue(De)}var Ge="propagation",He=new Be,Ve=function(){function e(){this.createBaggage=x,this.getBaggage=qe,this.getActiveBaggage=Fe,this.setBaggage=ze,this.deleteBaggage=Ue}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalPropagator=function(e){return l(Ge,e,v.instance())},e.prototype.inject=function(e,t,n){return void 0===n&&(n=X),this._getGlobalPropagator().inject(e,t,n)},e.prototype.extract=function(e,t,n){return void 0===n&&(n=J),this._getGlobalPropagator().extract(e,t,n)},e.prototype.fields=function(){return this._getGlobalPropagator().fields()},e.prototype.disable=function(){d(Ge,v.instance())},e.prototype._getGlobalPropagator=function(){return u(Ge)||He},e}(),Ke=Ve.getInstance(),We="trace",Je=function(){function e(){this._proxyTracerProvider=new je,this.wrapSpanContext=ge,this.isSpanContextValid=ve,this.deleteSpan=pe,this.getSpan=ae,this.getActiveSpan=se,this.getSpanContext=ue,this.setSpan=ce,this.setSpanContext=le}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalTracerProvider=function(e){var t=l(We,this._proxyTracerProvider,v.instance());return t&&this._proxyTracerProvider.setDelegate(e),t},e.prototype.getTracerProvider=function(){return u(We)||this._proxyTracerProvider},e.prototype.getTracer=function(e,t){return this.getTracerProvider().getTracer(e,t)},e.prototype.disable=function(){d(We,v.instance()),this._proxyTracerProvider=new je},e}().getInstance();const Xe={context:Re,diag:Le,metrics:Me,propagation:Ke,trace:Je}},7814(e){"use strict";if("undefined"!=typeof SharedArrayBuffer&&"undefined"!=typeof Atomics){const t=new Int32Array(new SharedArrayBuffer(4));function n(e){if(!1==(e>0&&e<1/0)){if("number"!=typeof e&&"bigint"!=typeof e)throw TypeError("sleep: ms must be a number");throw RangeError("sleep: ms must be a number that is greater than 0 but less than Infinity")}Atomics.wait(t,0,0,Number(e))}e.exports=n}else{function r(e){if(!1==(e>0&&e<1/0)){if("number"!=typeof e&&"bigint"!=typeof e)throw TypeError("sleep: ms must be a number");throw RangeError("sleep: ms must be a number that is greater than 0 but less than Infinity")}const t=Date.now()+Number(e);for(;t>Date.now(););}e.exports=r}},9746(e,t,n){"use strict";var r=n(7596).Buffer;e.exports=function(e){if(!e)throw new TypeError("argument req is required");if("object"!=typeof e)throw new TypeError("argument req is required to be an object");return a(function(e){if(!e.headers||"object"!=typeof e.headers)throw new TypeError("argument req is required to have headers property");return e.headers.authorization}(e))},e.exports.parse=a;var i=/^ *(?:[Bb][Aa][Ss][Ii][Cc]) +([A-Za-z0-9._~+/-]+=*) *$/,o=/^([^:]*):(.*)$/;function a(e){if("string"==typeof e){var t=i.exec(e);if(t){var n,a=o.exec((n=t[1],r.from(n,"base64").toString()));if(a)return new s(a[1],a[2])}}}function s(e,t){this.name=e,this.pass=t}},7596(e,t,n){var r=n(181),i=r.Buffer;function o(e,t){for(var n in e)t[n]=e[n]}function a(e,t,n){return i(e,t,n)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=r:(o(r,t),t.Buffer=a),o(i,a),a.from=function(e,t,n){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,n)},a.alloc=function(e,t,n){if("number"!=typeof e)throw new TypeError("Argument must be a number");var r=i(e);return void 0!==t?"string"==typeof n?r.fill(t,n):r.fill(t):r.fill(0),r},a.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return r.SlowBuffer(e)}},9159(e,t,n){e.exports={RBTree:n(6951),BinTree:n(4158)}},4158(e,t,n){var r=n(8930);function i(e){this.data=e,this.left=null,this.right=null}function o(e){this._root=null,this._comparator=e,this.size=0}i.prototype.get_child=function(e){return e?this.right:this.left},i.prototype.set_child=function(e,t){e?this.right=t:this.left=t},o.prototype=new r,o.prototype.insert=function(e){if(null===this._root)return this._root=new i(e),this.size++,!0;for(var t=0,n=null,r=this._root;;){if(null===r)return r=new i(e),n.set_child(t,r),ret=!0,this.size++,!0;if(0===this._comparator(r.data,e))return!1;t=this._comparator(r.data,e)<0,n=r,r=r.get_child(t)}},o.prototype.remove=function(e){if(null===this._root)return!1;var t=new i(void 0),n=t;n.right=this._root;for(var r=null,o=null,a=1;null!==n.get_child(a);){r=n,n=n.get_child(a);var s=this._comparator(e,n.data);a=s>0,0===s&&(o=n)}return null!==o&&(o.data=n.data,r.set_child(r.right===n,n.get_child(null===n.left)),this._root=t.right,this.size--,!0)},e.exports=o},6951(e,t,n){var r=n(8930);function i(e){this.data=e,this.left=null,this.right=null,this.red=!0}function o(e){this._root=null,this._comparator=e,this.size=0}function a(e){return null!==e&&e.red}function s(e,t){var n=e.get_child(!t);return e.set_child(!t,n.get_child(t)),n.set_child(t,e),e.red=!0,n.red=!1,n}function c(e,t){return e.set_child(!t,s(e.get_child(!t),!t)),s(e,t)}i.prototype.get_child=function(e){return e?this.right:this.left},i.prototype.set_child=function(e,t){e?this.right=t:this.left=t},o.prototype=new r,o.prototype.insert=function(e){var t=!1;if(null===this._root)this._root=new i(e),t=!0,this.size++;else{var n=new i(void 0),r=0,o=0,p=null,l=n,u=null,d=this._root;for(l.right=this._root;;){if(null===d?(d=new i(e),u.set_child(r,d),t=!0,this.size++):a(d.left)&&a(d.right)&&(d.red=!0,d.left.red=!1,d.right.red=!1),a(d)&&a(u)){var f=l.right===p;d===u.get_child(o)?l.set_child(f,s(p,!o)):l.set_child(f,c(p,!o))}var m=this._comparator(d.data,e);if(0===m)break;o=r,r=m<0,null!==p&&(l=p),p=u,u=d,d=d.get_child(r)}this._root=n.right}return this._root.red=!1,t},o.prototype.remove=function(e){if(null===this._root)return!1;var t=new i(void 0),n=t;n.right=this._root;for(var r=null,o=null,p=null,l=1;null!==n.get_child(l);){var u=l;o=r,r=n,n=n.get_child(l);var d=this._comparator(e,n.data);if(l=d>0,0===d&&(p=n),!a(n)&&!a(n.get_child(l)))if(a(n.get_child(!l))){var f=s(n,l);r.set_child(u,f),r=f}else if(!a(n.get_child(!l))){var m=r.get_child(!u);if(null!==m)if(a(m.get_child(!u))||a(m.get_child(u))){var h=o.right===r;a(m.get_child(u))?o.set_child(h,c(r,u)):a(m.get_child(!u))&&o.set_child(h,s(r,u));var v=o.get_child(h);v.red=!0,n.red=!0,v.left.red=!1,v.right.red=!1}else r.red=!1,m.red=!0,n.red=!0}}return null!==p&&(p.data=n.data,r.set_child(r.right===n,n.get_child(null===n.left)),this.size--),this._root=t.right,null!==this._root&&(this._root.red=!1),null!==p},e.exports=o},8930(e){function t(){}function n(e){this._tree=e,this._ancestors=[],this._cursor=null}t.prototype.clear=function(){this._root=null,this.size=0},t.prototype.find=function(e){for(var t=this._root;null!==t;){var n=this._comparator(e,t.data);if(0===n)return t.data;t=t.get_child(n>0)}return null},t.prototype.findIter=function(e){for(var t=this._root,n=this.iterator();null!==t;){var r=this._comparator(e,t.data);if(0===r)return n._cursor=t,n;n._ancestors.push(t),t=t.get_child(r>0)}return null},t.prototype.lowerBound=function(e){for(var t=this._root,n=this.iterator(),r=this._comparator;null!==t;){var i=r(e,t.data);if(0===i)return n._cursor=t,n;n._ancestors.push(t),t=t.get_child(i>0)}for(var o=n._ancestors.length-1;o>=0;--o)if(r(e,(t=n._ancestors[o]).data)<0)return n._cursor=t,n._ancestors.length=o,n;return n._ancestors.length=0,n},t.prototype.upperBound=function(e){for(var t=this.lowerBound(e),n=this._comparator;null!==t.data()&&0===n(t.data(),e);)t.next();return t},t.prototype.min=function(){var e=this._root;if(null===e)return null;for(;null!==e.left;)e=e.left;return e.data},t.prototype.max=function(){var e=this._root;if(null===e)return null;for(;null!==e.right;)e=e.right;return e.data},t.prototype.iterator=function(){return new n(this)},t.prototype.each=function(e){for(var t,n=this.iterator();null!==(t=n.next());)if(!1===e(t))return},t.prototype.reach=function(e){for(var t,n=this.iterator();null!==(t=n.prev());)if(!1===e(t))return},n.prototype.data=function(){return null!==this._cursor?this._cursor.data:null},n.prototype.next=function(){if(null===this._cursor){var e=this._tree._root;null!==e&&this._minNode(e)}else{var t;if(null===this._cursor.right)do{if(t=this._cursor,!this._ancestors.length){this._cursor=null;break}this._cursor=this._ancestors.pop()}while(this._cursor.right===t);else this._ancestors.push(this._cursor),this._minNode(this._cursor.right)}return null!==this._cursor?this._cursor.data:null},n.prototype.prev=function(){if(null===this._cursor){var e=this._tree._root;null!==e&&this._maxNode(e)}else{var t;if(null===this._cursor.left)do{if(t=this._cursor,!this._ancestors.length){this._cursor=null;break}this._cursor=this._ancestors.pop()}while(this._cursor.left===t);else this._ancestors.push(this._cursor),this._maxNode(this._cursor.left)}return null!==this._cursor?this._cursor.data:null},n.prototype._minNode=function(e){for(;null!==e.left;)this._ancestors.push(e),e=e.left;this._cursor=e},n.prototype._maxNode=function(e){for(;null!==e.right;)this._ancestors.push(e),e=e.right;this._cursor=e},e.exports=t},9440(e,t,n){"use strict";t=e.exports=function(){throw new Error("The bodyParser() generic has been split into individual middleware to use instead.")},Object.defineProperty(t,"json",{configurable:!0,enumerable:!0,get:()=>n(2899)}),Object.defineProperty(t,"raw",{configurable:!0,enumerable:!0,get:()=>n(1827)}),Object.defineProperty(t,"text",{configurable:!0,enumerable:!0,get:()=>n(1962)}),Object.defineProperty(t,"urlencoded",{configurable:!0,enumerable:!0,get:()=>n(4244)})},3499(e,t,n){"use strict";var r=n(2771),i=n(7680),o=n(5249),a=n(5649),s=n(8522),c=n(1592).hasBody,{getCharset:p}=n(1822);e.exports=function(e,t,n,l,u,d){if(a.isFinished(e))return u("body already parsed"),void n();if("body"in e||(e.body=void 0),!c(e))return u("skip empty body"),void n();if(u("content-type %j",e.headers["content-type"]),!d.shouldParse(e))return u("skip parsing"),void n();var f,m=null;if(!0!==d?.skipCharset&&(m=p(e)||d.defaultCharset,d?.isValidCharset&&!d.isValidCharset(m)))return u("invalid charset"),void n(r(415,'unsupported charset "'+m.toUpperCase()+'"',{charset:m,type:"charset.unsupported"}));var h,v=d,g=v.verify;try{h=function(e,t,n){var i=(e.headers["content-encoding"]||"identity").toLowerCase(),o=e.headers["content-length"];if(t('content-encoding "%s"',i),!1===n&&"identity"!==i)throw r(415,"content encoding unsupported",{encoding:i,type:"encoding.unsupported"});if("identity"===i)return e.length=o,e;var a=function(e,t){switch(e){case"deflate":return t("inflate body"),s.createInflate();case"gzip":return t("gunzip body"),s.createGunzip();case"br":return t("brotli decompress body"),s.createBrotliDecompress();default:throw r(415,'unsupported content encoding "'+e+'"',{encoding:e,type:"encoding.unsupported"})}}(i,t);return e.pipe(a),a}(e,u,v.inflate),f=h.length,h.length=void 0}catch(e){return n(e)}if(v.length=f,v.encoding=g?null:m,null===v.encoding&&null!==m&&!o.encodingExists(m))return n(r(415,'unsupported charset "'+m.toUpperCase()+'"',{charset:m.toLowerCase(),type:"charset.unsupported"}));u("read body"),i(h,v,function(i,s){var c;if(i)return c="encoding.unsupported"===i.type?r(415,'unsupported charset "'+m.toUpperCase()+'"',{charset:m.toLowerCase(),type:"charset.unsupported"}):r(400,i),h!==e&&(e.unpipe(),h.destroy()),void function(e,t){a.isFinished(e)?t():(a(e,t),e.resume())}(e,function(){n(r(400,c))});if(g)try{u("verify body"),g(e,t,s,m)}catch(e){return void n(r(403,e,{body:s,type:e.type||"entity.verify.failed"}))}var p=s;try{u("parse body"),p="string"!=typeof s&&null!==m?o.decode(s,m):s,e.body=l(p,m)}catch(e){return void n(r(400,e,{body:p,type:e.type||"entity.parse.failed"}))}n()})}},2899(e,t,n){"use strict";var r=n(5753)("body-parser:json"),i=n(3499),{normalizeOptions:o}=n(1822);e.exports=function(e){const t=o(e,"application/json");var n=e?.reviver,p=!1!==e?.strict;function l(e){if(0===e.length)return{};if(p){var t=(i=e,(o=a.exec(i))?o[1]:void 0);if("{"!==t&&"["!==t)throw r("strict violation"),function(e,t){var n=e.indexOf(t),r="";-1!==n&&(r=e.substring(0,n)+"#".repeat(e.length-n));try{throw JSON.parse(r),new SyntaxError("strict violation")}catch(t){return c(t,{message:t.message.replace(s,function(t){return e.substring(n,n+t.length)}),stack:t.stack})}}(e,t)}var i,o;try{return r("parse json"),JSON.parse(e,n)}catch(e){throw c(e,{message:e.message,stack:e.stack})}}const u={...t,isValidCharset:e=>"utf-"===e.slice(0,4)};return function(e,t,n){i(e,t,n,l,r,u)}};var a=/^[\x20\x09\x0a\x0d]*([^\x20\x09\x0a\x0d])/,s=/#+/g;function c(e,t){for(var n=Object.getOwnPropertyNames(e),r=0;r<n.length;r++){var i=n[r];"stack"!==i&&"message"!==i&&delete e[i]}return e.stack=t.stack.replace(e.message,t.message),e.message=t.message,e}},1827(e,t,n){"use strict";var r=n(5753)("body-parser:raw"),i=n(3499),{normalizeOptions:o,passthrough:a}=n(1822);e.exports=function(e){const t={...o(e,"application/octet-stream"),skipCharset:!0};return function(e,n,o){i(e,n,o,a,r,t)}}},1962(e,t,n){"use strict";var r=n(5753)("body-parser:text"),i=n(3499),{normalizeOptions:o,passthrough:a}=n(1822);e.exports=function(e){const t=o(e,"text/plain");return function(e,n,o){i(e,n,o,a,r,t)}}},4244(e,t,n){"use strict";var r=n(2771),i=n(5753)("body-parser:urlencoded"),o=n(3499),a=n(5373),{normalizeOptions:s}=n(1822);e.exports=function(e){const t=s(e,"application/x-www-form-urlencoded");if("utf-8"!==t.defaultCharset&&"iso-8859-1"!==t.defaultCharset)throw new TypeError("option defaultCharset must be either utf-8 or iso-8859-1");var n=function(e){var t=Boolean(e?.extended),n=void 0!==e?.parameterLimit?e?.parameterLimit:1e3,o=e?.charsetSentinel,s=e?.interpretNumericEntities,c=t?void 0!==e?.depth?e?.depth:32:0;if(isNaN(n)||n<1)throw new TypeError("option parameterLimit must be a positive number");if(isNaN(c)||c<0)throw new TypeError("option depth must be a zero or a positive number");return isFinite(n)&&(n|=0),function(e,p){var l=function(e,t){let n=0,r=-1;do{if(n++,n>t)return;r=e.indexOf("&",r+1)}while(-1!==r);return n}(e,n);if(void 0===l)throw i("too many parameters"),r(413,"too many parameters",{type:"parameters.too.many"});var u=t?Math.max(100,l):l;i("parse "+(t?"extended ":"")+"urlencoding");try{return a.parse(e,{allowPrototypes:!0,arrayLimit:u,depth:c,charsetSentinel:o,interpretNumericEntities:s,charset:p,parameterLimit:n,strictDepth:!0})}catch(e){throw e instanceof RangeError?r(400,"The input exceeded the depth",{type:"querystring.parse.rangeError"}):e}}}(e);function c(e,t){return e.length?n(e,t):{}}const p={...t,isValidCharset:e=>"utf-8"===e||"iso-8859-1"===e};return function(e,t,n){o(e,t,n,c,i,p)}}},1822(e,t,n){"use strict";var r=n(5508),i=n(8597),o=n(1592);e.exports={getCharset:function(e){try{return(i.parse(e).parameters.charset||"").toLowerCase()}catch{return}},normalizeOptions:function(e,t){if(!t)throw new TypeError("defaultType must be provided");var n=!1!==e?.inflate,i="number"!=typeof e?.limit?r.parse(e?.limit||"100kb"):e?.limit,a=e?.type||t,s=e?.verify||!1,c=e?.defaultCharset||"utf-8";if(!1!==s&&"function"!=typeof s)throw new TypeError("option verify must be function");return{inflate:n,limit:i,verify:s,defaultCharset:c,shouldParse:"function"!=typeof a?function(e){return function(t){return Boolean(o(t,e))}}(a):a}},passthrough:function(e){return e}}},1045(e,t,n){"use strict";var r=n(181).Buffer,i=n(181).SlowBuffer;function o(e,t){if(!r.isBuffer(e)||!r.isBuffer(t))return!1;if(e.length!==t.length)return!1;for(var n=0,i=0;i<e.length;i++)n|=e[i]^t[i];return 0===n}e.exports=o,o.install=function(){r.prototype.equal=i.prototype.equal=function(e){return o(this,e)}};var a=r.prototype.equal,s=i.prototype.equal;o.restore=function(){r.prototype.equal=a,i.prototype.equal=s}},5508(e){"use strict";e.exports=function(e,t){return"string"==typeof e?a(e):"number"==typeof e?o(e,t):null},e.exports.format=o,e.exports.parse=a;var t=/\B(?=(\d{3})+(?!\d))/g,n=/(?:\.0*|(\.[^0]+)0+)$/,r={b:1,kb:1024,mb:1<<20,gb:1<<30,tb:Math.pow(1024,4),pb:Math.pow(1024,5)},i=/^((-|\+)?(\d+(?:\.\d+)?)) *(kb|mb|gb|tb|pb)$/i;function o(e,i){if(!Number.isFinite(e))return null;var o=Math.abs(e),a=i&&i.thousandsSeparator||"",s=i&&i.unitSeparator||"",c=i&&void 0!==i.decimalPlaces?i.decimalPlaces:2,p=Boolean(i&&i.fixedDecimals),l=i&&i.unit||"";l&&r[l.toLowerCase()]||(l=o>=r.pb?"PB":o>=r.tb?"TB":o>=r.gb?"GB":o>=r.mb?"MB":o>=r.kb?"KB":"B");var u=(e/r[l.toLowerCase()]).toFixed(c);return p||(u=u.replace(n,"$1")),a&&(u=u.split(".").map(function(e,n){return 0===n?e.replace(t,a):e}).join(".")),u+s+l}function a(e){if("number"==typeof e&&!isNaN(e))return e;if("string"!=typeof e)return null;var t,n=i.exec(e),o="b";return n?(t=parseFloat(n[1]),o=n[4].toLowerCase()):(t=parseInt(e,10),o="b"),isNaN(t)?null:Math.floor(r[o]*t)}},3144(e,t,n){"use strict";var r=n(6743),i=n(1002),o=n(76),a=n(7119);e.exports=a||r.call(o,i)},1002(e){"use strict";e.exports=Function.prototype.apply},76(e){"use strict";e.exports=Function.prototype.call},3126(e,t,n){"use strict";var r=n(6743),i=n(9675),o=n(76),a=n(3144);e.exports=function(e){if(e.length<1||"function"!=typeof e[0])throw new i("a function is required");return a(r,o,e)}},7119(e){"use strict";e.exports="undefined"!=typeof Reflect&&Reflect&&Reflect.apply},6556(e,t,n){"use strict";var r=n(453),i=n(3126),o=i([r("%String.prototype.indexOf%")]);e.exports=function(e,t){var n=r(e,!!t);return"function"==typeof n&&o(e,".prototype.")>-1?i([n]):n}},1957(e,t,n){"use strict";var r=n(7598),i=/^text\/|\+(?:json|text|xml)$/i,o=/^\s*([^;\s]*)(?:;|\s|$)/;e.exports=function(e){if(!e||"string"!=typeof e)return!1;var t=o.exec(e),n=t&&t[1].toLowerCase(),a=r[n];return a&&void 0!==a.compressible?a.compressible:i.test(n)||void 0}},9661(e,t,n){"use strict";var r=n(1297),i=n(2861).Buffer,o=n(5508),a=n(1957),s=n(9489)("compression"),c=n(6099),p=n(677),l=n(3106);e.exports=function(e){var t=e||{},n={};if(u){Object.assign(n,t.brotli);var a={};a[l.constants.BROTLI_PARAM_QUALITY]=4,n.params=Object.assign(a,n.params)}var x=t.filter||g,w=o.parse(t.threshold),E=t.enforceEncoding||"identity";return null==w&&(w=1024),function(e,o,a){var u,g,_=!1,S=[],O=o.end,j=o.on,k=o.write;function A(e){s("no compression: %s",e),v(o,j,S),S=null}o.flush=function(){g&&g.flush()},o.write=function(e,t){return!_&&(y(o)||this.writeHead(this.statusCode),g?g.write(b(e,t)):k.call(this,e,t))},o.end=function(e,t){return!_&&(y(o)||(this.getHeader("Content-Length")||(u=function(e,t){return e?i.isBuffer(e)?e.length:i.byteLength(e,t):0}(e,t)),this.writeHead(this.statusCode)),g?(_=!0,e?g.end(b(e,t)):g.end()):O.call(this,e,t))},o.on=function(e,t){return S&&"drain"===e?g?g.on(e,t):(S.push([e,t]),this):j.call(this,e,t)},c(o,function(){if(x(e,o))if(function(e,t){var n=t.getHeader("Cache-Control");return!n||!d.test(n)}(0,o))if(p(o,"Accept-Encoding"),Number(o.getHeader("Content-Length"))<w||u<w)A("size below threshold");else if("identity"===(o.getHeader("Content-Encoding")||"identity"))if("HEAD"!==e.method){var i=new r(e).encoding(f,m);e.headers["accept-encoding"]||-1===h.indexOf(E)||(i=E),i&&"identity"!==i?(s("%s compression",i),v(g="gzip"===i?l.createGzip(t):"br"===i?l.createBrotliCompress(n):l.createDeflate(t),g.on,S),o.setHeader("Content-Encoding",i),o.removeHeader("Content-Length"),g.on("data",function(e){!1===k.call(o,e)&&g.pause()}),g.on("end",function(){O.call(o)}),j.call(o,"drain",function(){g.resume()})):A("not acceptable")}else A("HEAD request");else A("already encoded");else A("no transform");else A("filtered")}),a()}},e.exports.filter=g;var u="createBrotliCompress"in l,d=/(?:^|,)\s*?no-transform\s*?(?:,|$)/,f=u?["br","gzip","deflate","identity"]:["gzip","deflate","identity"],m=u?["br","gzip"]:["gzip"],h=["gzip","deflate","identity","br"];function v(e,t,n){for(var r=0;r<n.length;r++)t.apply(e,n[r])}function g(e,t){var n=t.getHeader("Content-Type");return!(void 0===n||!a(n))||(s("%s not compressible",n),!1)}function b(e,t){return i.isBuffer(e)?e:i.from(e,t)}function y(e){return"boolean"!=typeof e.headersSent?Boolean(e._header):e.headersSent}},8673(e,t,n){function r(){var e;try{e=t.storage.debug}catch(e){}return!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG),e}(t=e.exports=n(8526)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))}),e.splice(o,0,r)}},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=r,t.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(r())},8526(e,t,n){var r;function i(e){function n(){if(n.enabled){var e=n,i=+new Date,o=i-(r||i);e.diff=o,e.prev=r,e.curr=i,r=i;for(var a=new Array(arguments.length),s=0;s<a.length;s++)a[s]=arguments[s];a[0]=t.coerce(a[0]),"string"!=typeof a[0]&&a.unshift("%O");var c=0;a[0]=a[0].replace(/%([a-zA-Z%])/g,function(n,r){if("%%"===n)return n;c++;var i=t.formatters[r];if("function"==typeof i){var o=a[c];n=i.call(e,o),a.splice(c,1),c--}return n}),t.formatArgs.call(e,a),(n.log||t.log||console.log.bind(console)).apply(e,a)}}return n.namespace=e,n.enabled=t.enabled(e),n.useColors=t.useColors(),n.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),"function"==typeof t.init&&t.init(n),n}(t=e.exports=i.debug=i.default=i).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){t.save(e),t.names=[],t.skips=[];for(var n=("string"==typeof e?e:"").split(/[\s,]+/),r=n.length,i=0;i<r;i++)n[i]&&("-"===(e=n[i].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(8993),t.names=[],t.skips=[],t.formatters={}},9489(e,t,n){"undefined"!=typeof process&&"renderer"===process.type?e.exports=n(8673):e.exports=n(3865)},3865(e,t,n){var r=n(2018),i=n(9023);(t=e.exports=n(8526)).init=function(e){e.inspectOpts={};for(var n=Object.keys(t.inspectOpts),r=0;r<n.length;r++)e.inspectOpts[n[r]]=t.inspectOpts[n[r]]},t.log=function(){return a.write(i.format.apply(i,arguments)+"\n")},t.formatArgs=function(e){var n=this.namespace;if(this.useColors){var r=this.color,i=" [3"+r+";1m"+n+" [0m";e[0]=i+e[0].split("\n").join("\n"+i),e.push("[3"+r+"m+"+t.humanize(this.diff)+"[0m")}else e[0]=(new Date).toUTCString()+" "+n+" "+e[0]},t.save=function(e){null==e?delete process.env.DEBUG:process.env.DEBUG=e},t.load=s,t.useColors=function(){return"colors"in t.inspectOpts?Boolean(t.inspectOpts.colors):r.isatty(o)},t.colors=[6,2,3,4,5,1],t.inspectOpts=Object.keys(process.env).filter(function(e){return/^debug_/i.test(e)}).reduce(function(e,t){var n=t.substring(6).toLowerCase().replace(/_([a-z])/g,function(e,t){return t.toUpperCase()}),r=process.env[t];return r=!!/^(yes|on|true|enabled)$/i.test(r)||!/^(no|off|false|disabled)$/i.test(r)&&("null"===r?null:Number(r)),e[n]=r,e},{});var o=parseInt(process.env.DEBUG_FD,10)||2;1!==o&&2!==o&&i.deprecate(function(){},"except for stderr(2) and stdout(1), any other usage of DEBUG_FD is deprecated. Override debug.log if you want to use a different log function (https://git.io/debug_fd)")();var a=1===o?process.stdout:2===o?process.stderr:function(e){var t;switch(process.binding("tty_wrap").guessHandleType(e)){case"TTY":(t=new r.WriteStream(e))._type="tty",t._handle&&t._handle.unref&&t._handle.unref();break;case"FILE":(t=new(n(9896).SyncWriteStream)(e,{autoClose:!1}))._type="fs";break;case"PIPE":case"TCP":(t=new(n(9278).Socket)({fd:e,readable:!1,writable:!0})).readable=!1,t.read=null,t._type="pipe",t._handle&&t._handle.unref&&t._handle.unref();break;default:throw new Error("Implement me. Unknown stream file type!")}return t.fd=e,t._isStdio=!0,t}(o);function s(){return process.env.DEBUG}t.formatters.o=function(e){return this.inspectOpts.colors=this.useColors,i.inspect(e,this.inspectOpts).split("\n").map(function(e){return e.trim()}).join(" ")},t.formatters.O=function(e){return this.inspectOpts.colors=this.useColors,i.inspect(e,this.inspectOpts)},t.enable(s())},8993(e){var t=1e3,n=60*t,r=60*n,i=24*r;function o(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,a){a=a||{};var s,c=typeof e;if("string"===c&&e.length>0)return function(e){if(!((e=String(e)).length>100)){var o=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(o){var a=parseFloat(o[1]);switch((o[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*a;case"days":case"day":case"d":return a*i;case"hours":case"hour":case"hrs":case"hr":case"h":return a*r;case"minutes":case"minute":case"mins":case"min":case"m":return a*n;case"seconds":case"second":case"secs":case"sec":case"s":return a*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}(e);if("number"===c&&!1===isNaN(e))return a.long?o(s=e,i,"day")||o(s,r,"hour")||o(s,n,"minute")||o(s,t,"second")||s+" ms":function(e){return e>=i?Math.round(e/i)+"d":e>=r?Math.round(e/r)+"h":e>=n?Math.round(e/n)+"m":e>=t?Math.round(e/t)+"s":e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},8597(e,t){"use strict";var n=/; *([!#$%&'*+.^_`|~0-9A-Za-z-]+) *= *("(?:[\u000b\u0020\u0021\u0023-\u005b\u005d-\u007e\u0080-\u00ff]|\\[\u000b\u0020-\u00ff])*"|[!#$%&'*+.^_`|~0-9A-Za-z-]+) */g,r=/^[\u000b\u0020-\u007e\u0080-\u00ff]+$/,i=/^[!#$%&'*+.^_`|~0-9A-Za-z-]+$/,o=/\\([\u000b\u0020-\u00ff])/g,a=/([\\"])/g,s=/^[!#$%&'*+.^_`|~0-9A-Za-z-]+\/[!#$%&'*+.^_`|~0-9A-Za-z-]+$/;function c(e){var t=String(e);if(i.test(t))return t;if(t.length>0&&!r.test(t))throw new TypeError("invalid parameter value");return'"'+t.replace(a,"\\$1")+'"'}function p(e){this.parameters=Object.create(null),this.type=e}t.format=function(e){if(!e||"object"!=typeof e)throw new TypeError("argument obj is required");var t=e.parameters,n=e.type;if(!n||!s.test(n))throw new TypeError("invalid type");var r=n;if(t&&"object"==typeof t)for(var o,a=Object.keys(t).sort(),p=0;p<a.length;p++){if(o=a[p],!i.test(o))throw new TypeError("invalid parameter name");r+="; "+o+"="+c(t[o])}return r},t.parse=function(e){if(!e)throw new TypeError("argument string is required");var t="object"==typeof e?function(e){var t;if("function"==typeof e.getHeader?t=e.getHeader("content-type"):"object"==typeof e.headers&&(t=e.headers&&e.headers["content-type"]),"string"!=typeof t)throw new TypeError("content-type header is missing from object");return t}(e):e;if("string"!=typeof t)throw new TypeError("argument string is required to be a string");var r=t.indexOf(";"),i=-1!==r?t.slice(0,r).trim():t.trim();if(!s.test(i))throw new TypeError("invalid media type");var a=new p(i.toLowerCase());if(-1!==r){var c,l,u;for(n.lastIndex=r;l=n.exec(t);){if(l.index!==r)throw new TypeError("invalid parameter format");r+=l[0].length,c=l[1].toLowerCase(),34===(u=l[2]).charCodeAt(0)&&-1!==(u=u.slice(1,-1)).indexOf("\\")&&(u=u.replace(o,"$1")),a.parameters[c]=u}if(r!==t.length)throw new TypeError("invalid parameter format")}return a}},9728(e,t,n){!function(){"use strict";var t=n(5228),r=n(677),i={origin:"*",methods:"GET,HEAD,PUT,PATCH,POST,DELETE",preflightContinue:!1,optionsSuccessStatus:204};function o(e){return"string"==typeof e||e instanceof String}function a(e,t){if(Array.isArray(t)){for(var n=0;n<t.length;++n)if(a(e,t[n]))return!0;return!1}return o(t)?e===t:t instanceof RegExp?t.test(e):!!t}function s(e,t){var n,r=t.headers.origin,i=[];return e.origin&&"*"!==e.origin?o(e.origin)?(i.push([{key:"Access-Control-Allow-Origin",value:e.origin}]),i.push([{key:"Vary",value:"Origin"}])):(n=a(r,e.origin),i.push([{key:"Access-Control-Allow-Origin",value:!!n&&r}]),i.push([{key:"Vary",value:"Origin"}])):i.push([{key:"Access-Control-Allow-Origin",value:"*"}]),i}function c(e){return!0===e.credentials?{key:"Access-Control-Allow-Credentials",value:"true"}:null}function p(e){var t=e.exposedHeaders;return t?(t.join&&(t=t.join(",")),t&&t.length?{key:"Access-Control-Expose-Headers",value:t}:null):null}function l(e,t){for(var n=0,i=e.length;n<i;n++){var o=e[n];o&&(Array.isArray(o)?l(o,t):"Vary"===o.key&&o.value?r(t,o.value):o.value&&t.setHeader(o.key,o.value))}}e.exports=function(e){var n=null;return n="function"==typeof e?e:function(t,n){n(null,e)},function(e,r,o){n(e,function(n,a){if(n)o(n);else{var u=t({},i,a),d=null;u.origin&&"function"==typeof u.origin?d=u.origin:u.origin&&(d=function(e,t){t(null,u.origin)}),d?d(e.headers.origin,function(t,n){t||!n?o(t):(u.origin=n,function(e,t,n,r){var i=[];"OPTIONS"===(t.method&&t.method.toUpperCase&&t.method.toUpperCase())?(i.push(s(e,t)),i.push(c(e)),i.push(function(e){var t=e.methods;return t.join&&(t=e.methods.join(",")),{key:"Access-Control-Allow-Methods",value:t}}(e)),i.push(function(e,t){var n=e.allowedHeaders||e.headers,r=[];return n?n.join&&(n=n.join(",")):(n=t.headers["access-control-request-headers"],r.push([{key:"Vary",value:"Access-Control-Request-Headers"}])),n&&n.length&&r.push([{key:"Access-Control-Allow-Headers",value:n}]),r}(e,t)),i.push(function(e){var t=("number"==typeof e.maxAge||e.maxAge)&&e.maxAge.toString();return t&&t.length?{key:"Access-Control-Max-Age",value:t}:null}(e)),i.push(p(e)),l(i,n),e.preflightContinue?r():(n.statusCode=e.optionsSuccessStatus,n.setHeader("Content-Length","0"),n.end())):(i.push(s(e,t)),i.push(c(e)),i.push(p(e)),l(i,n),r())}(u,e,r,o))}):o()}})}}}()},7833(e,t,n){t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,e=>{"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")||t.storage.getItem("DEBUG")}catch(e){}return!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG),e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0