MCPcopy
hub / github.com/UnblockNeteaseMusic/server / z

Function z

precompiled/bridge.js:9–9  ·  view source on GitHub ↗
(e,t)

Source from the content-addressed store, hash-verified

7`}){let i=e.split(/\r?\n/);for(let e=1;e<i.length;e+=1)i[e]=t+i[e];return i.join(r)}function x({input:e,ident:t=" ",eol:r=`
8`,skipKeys:i=[],customPrettifiers:o={},errorLikeKeys:s=f,excludeLoggerKeys:u=!0,singleLine:l=!1,colorizer:h=c}){let d=[].concat(i);!0===u&&Array.prototype.push.apply(d,g);let p="",{plain:y,errors:m}=Object.entries(e).reduce(({plain:t,errors:r},[i,a])=>{if(!1===d.includes(i)){let u="function"==typeof o[i]?o[i](a,i,e):a;s.includes(i)?r[i]=u:t[i]=u}return{plain:t,errors:r}},{plain:{},errors:{}});return l?(Object.keys(y).length>0&&(p+=h.greyMessage(a(y))),p+=r):Object.entries(y).forEach(([e,i])=>{let s="function"==typeof o[e]?i:a(i,null,2);if(void 0===s)return;let u=S({input:s,ident:t,eol:r});p+=`${t}${e}:${u.startsWith(r)?"":" "}${u}${r}`}),Object.entries(m).forEach(([e,i])=>{let s="function"==typeof o[e]?i:a(i,null,2);void 0!==s&&(p+=E({keyName:e,lines:s,eol:r,ident:t}))}),p}function E({keyName:e,lines:t,eol:r,ident:i}){let o="",s=S({input:t,ident:i,eol:r}),a=`${i}${e}: ${s}${r}`.split(r);for(let e=0;e<a.length;e+=1){0!==e&&(o+=r);let t=a[e];if(/^\s*"stack"/.test(t)){let e=/^(\s*"stack":)\s*(".*"),?$/.exec(t);if(e&&3===e.length){let i=/^\s*/.exec(t)[0].length+4,s=" ".repeat(i),a=e[2];o+=e[1]+r+s+JSON.parse(a).replace(/\n/g,r+s)}else o+=t}else o+=t}return o}function O(e){let t=[],r=!1,i="";for(let o=0;o<e.length;o++){let s=e.charAt(o);if("\\"===s){r=!0;continue}if(r){r=!1,i+=s;continue}if("."===s){t.push(i),i="";continue}i+=s}return i.length&&t.push(i),t}function j(e,t){let r=O(t),i=r.pop();r.forEach(t=>{Object.prototype.hasOwnProperty.call(e,t)&&(e=e[t])}),delete e[i]}function k(){}function T(e,t){e.destroyed||("beforeExit"===t?(e.flush(),e.on("drain",function(){e.end()})):e.flushSync())}e.exports={isObject:_,prettifyErrorLog:function({log:e,messageKey:t=h,ident:r=" ",eol:i=`
9`,errorLikeKeys:o=f,errorProperties:s=[]}){let a=S({input:e.stack,ident:r,eol:i}),u=`${r}${a}${i}`;if(s.length>0){let a,c=g.concat(t,"type","stack");a="*"===s[0]?Object.keys(e).filter(e=>!1===c.includes(e)):s.filter(e=>!1===c.includes(e));for(let t=0;t<a.length;t+=1){let s=a[t];if(s in e!=!1){if(_(e[s])){let t=x({input:e[s],errorLikeKeys:o,excludeLoggerKeys:!1,eol:i,ident:r+r});u=`${u}${r}${s}: {${i}${t}${r}}${i}`;continue}u=`${u}${r}${s}: ${e[s]}${i}`}}}return u},prettifyLevel:function({log:e,colorizer:t=c,levelKey:r=d,prettifier:i,customLevels:o,customLevelNames:s}){if(r in e==!1)return;let a=e[r];return i?i(a):t(a,{customLevels:o,customLevelNames:s})},prettifyMessage:function({log:e,messageFormat:t,messageKey:r=h,colorizer:i=c,levelLabel:o=p,levelKey:s=d,customLevels:a,useOnlyCustomProps:u}){if(t&&"string"==typeof t){let r=String(t).replace(/{([^{}]+)}/g,function(t,r){return r===o&&e[s]?(u?void 0===a:void 0===a[e[s]])?m[e[s]]:a[e[s]]:r.split(".").reduce(function(e,t){return e&&e[t]?e[t]:""},e)});return i.message(r)}if(t&&"function"==typeof t){let s=t(e,r,o);return i.message(s)}if(r in e!=!1&&"string"==typeof e[r])return i.message(e[r])},prettifyMetadata:function({log:e,prettifiers:t={}}){let r="";if(e.name||e.pid||e.hostname){if(r+="(",e.name&&(r+=t.name?t.name(e.name):e.name),e.pid){let i=t.pid?t.pid(e.pid):e.pid;e.name&&e.pid?r+="/"+i:r+=i}e.hostname&&(r+=`${"("===r?"on":" on"} ${t.hostname?t.hostname(e.hostname):e.hostname}`),r+=")"}if(e.caller&&(r+=`${""===r?"":" "}<${t.caller?t.caller(e.caller):e.caller}>`),""!==r)return r},prettifyObject:x,prettifyTime:function({log:e,timestampKey:t=y,translateFormat:r,prettifier:i}){let o=null;if(t in e?o=e[t]:"timestamp"in e&&(o=e.timestamp),null===o)return;let s=r?b(o,r):o;return i?i(s):`[${s}]`},buildSafeSonicBoom:function(e){let t=new s(e);return t.on("error",function e(r){if("EPIPE"===r.code){t.write=k,t.end=k,t.flushSync=k,t.destroy=k;return}t.removeListener("error",e)}),!e.sync&&u&&function(e){if(global.WeakRef&&global.WeakMap&&global.FinalizationRegistry){let t=r(5463);t.register(e,T),e.on("close",function(){t.unregister(e)})}}(t),t},filterLog:function(e,t){let r=i(e);return t.forEach(e=>{j(r,e)}),r}},e.exports.internals={formatTime:b,joinLinesWithIndentation:S,prettifyError:E,deleteLogProperty:j,splitIgnoreKey:O,createDate:v,isValidDate:w}},2397:(e,t,r)=>{"use strict";var i,o=r(4526),s=r(82),a=r(8350),u=r(1088),c=r(9854),l=r(4298),f=r(8364),h="prototype",d="script",p=f("IE_PROTO"),y=function(){},g=function(e){return"<"+d+">"+e+"</"+d+">"},m=function(e){e.write(g("")),e.close();var t=e.parentWindow.Object;return e=null,t},b=function(){var e,t=l("iframe");return t.style.display="none",c.appendChild(t),t.src=String("java"+d+":"),(e=t.contentWindow.document).open(),e.write(g("document.F=Object")),e.close(),e.F},v=function(){try{i=new ActiveXObject("htmlfile")}catch(e){}v="undefined"!=typeof document?document.domain&&i?m(i):b():m(i);for(var e=a.length;e--;)delete v[h][a[e]];return v()};u[p]=!0,e.exports=Object.create||function(e,t){var r;return null!==e?(y[h]=o(e),r=new y,y[h]=null,r[p]=e):r=v(),void 0===t?r:s.f(r,t)}},2436:(e,t,r)=>{"use strict";var i=r(3892),o=r(6078),s=r(2025).String;e.exports=!!Object.getOwnPropertySymbols&&!o(function(){var e=Symbol("symbol detection");return!s(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&i&&i<41})},2448:(e,t,r)=>{"use strict";var i=r(697),o=r(2675),s=r(6465),a=s.get,u=s.has,c=s.set;i({target:"Map",proto:!0,real:!0,forced:!0},{emplace:function(e,t){var r,i,s=o(this);return u(s,e)?(r=a(s,e),"update"in t&&(r=t.update(r,e,s),c(s,e,r)),r):(i=t.insert(e,s),c(s,e,i),i)}})},2552:(e,t,r)=>{"use strict";var i=r(697),o=r(1196),s=r(1999),a=r(823);i({target:"Set",proto:!0,real:!0,forced:!0},{difference:function(e){return o(a,this,s(e))}})},2664:(e,t,r)=>{e.exports=r(9023).deprecate},2672:(e,t,r)=>{"use strict";let i=r(4434),o="cancel";e.exports={CancelRequest:class extends i{cancelled=!1;cancel(){this.cancelled=!0,this.emit(o)}},ON_CANCEL:o}},2675:(e,t,r)=>{"use strict";var i=r(6465).has;e.exports=function(e){return i(e),e}},2732:(e,t,r)=>{"use strict";var i=r(8585),o=r(6475),s=TypeError,a=Object.getOwnPropertyDescriptor;e.exports=i&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}()?function(e,t){if(o(e)&&!a(e,"length").writable)throw new s("Cannot set read only .length");return e.length=t}:function(e,t){return e.length=t}},2736:(e,t,r)=>{"use strict";var i=r(697),o=r(4689),s=r(5773),a=r(9900);i({target:"Set",proto:!0,real:!0,forced:!0},{every:function(e){var t=s(this),r=o(e,arguments.length>1?arguments[1]:void 0);return!1!==a(t,function(e){if(!r(e,e,t))return!1},!0)}})},2749:(e,t,r)=>{"use strict";var i=r(5773),o=r(7417),s=r(9900),a=r(1428);e.exports=function(e){var t=i(this),r=a(e);return!(o(t)>r.size)&&!1!==s(t,function(e){if(!r.includes(e))return!1},!0)}},2777:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),r(777),r(9071),r(4914);let i=r(9588),o=r(3186),s=r(23),a=r(2965),{getManagedCacheStorage:u}=r(4337),c=e=>({id:e.hash,id_hq:e["320hash"],id_sq:e.sqhash,name:e.songname,duration:1e3*e.duration,album:{id:e.album_id,name:e.album_name}}),l=e=>a("GET","http://mobilecdn.kugou.com/api/v3/search/song?keyword="+encodeURIComponent(e.keyword)+"&page=1&pagesize=10").then(e=>e.json()).then(t=>o(t.data.info.map(c),e)||Promise.reject()).catch(()=>i().kugou.search(e)),f=e=>Promise.all(["sqhash","hqhash","hash"].slice(+!o.ENABLE_FLAC).map(t=>((e,t)=>{let r=()=>{switch(t){case"hash":return e.id;case"hqhash":return e.id_hq;case"sqhash":return e.id_sq}return""};return a("GET","http://trackercdn.kugou.com/i/v2/?key="+s.md5.digest(`${r()}kgcloudv2`)+"&hash="+r()+"&appid=1005&pid=2&cmd=25&behavior=play&album_id="+e.album.id).then(e=>e.json()).then(e=>e.url[0]||Promise.reject())})(e,t).catch(()=>null))).then(e=>e.find(e=>e)||Promise.reject()).catch(()=>i().kugou.track(e)),h=u("provider/kugou");e.exports={check:e=>h.cache(e,()=>l(e)).then(f),search:l}},2862:(e,t,r)=>{"use strict";r(2083)},2870:(e,t,r)=>{"use strict";var i=r(8173),o=r(5032),s=i({}.hasOwnProperty);e.exports=Object.hasOwn||function(e,t){return s(o(e),t)}},2896:(e,t,r)=>{var i=r(9491),o=r(5486),s=r(3081),a=r(3049),u=Buffer.from&&Buffer.from!==Uint8Array.from?Buffer.from([0]):new Buffer([0]),c=function(e,t){e._corked?e.once("uncork",t):t()},l=function(e,t){e._autoDestroy&&e.destroy(t)},f=function(e,t){return function(r){r?l(e,"premature close"===r.message?null:r):t&&!e._ended&&e.end()}},h=function(){},d=function(e,t,r){if(!(this instanceof d))return new d(e,t,r);i.Duplex.call(this,r),this._writable=null,this._readable=null,this._readable2=null,this._autoDestroy=!r||!1!==r.autoDestroy,this._forwardDestroy=!r||!1!==r.destroy,this._forwardEnd=!r||!1!==r.end,this._corked=1,this._ondrain=null,this._drained=!1,this._forwarding=!1,this._unwrite=null,this._unread=null,this._ended=!1,this.destroyed=!1,e&&this.setWritable(e),t&&this.setReadable(t)};s(d,i.Duplex),d.obj=function(e,t,r){return r||(r={}),r.objectMode=!0,r.highWaterMark=16,new d(e,t,r)},d.prototype.cork=function(){1==++this._corked&&this.emit("cork")},d.prototype.uncork=function(){this._corked&&0==--this._corked&&this.emit("uncork")},d.prototype.setWritable=function(e){if(this._unwrite&&this._unwrite(),this.destroyed){e&&e.destroy&&e.destroy();return}if(null===e||!1===e)return void this.end();var t=this,r=o(e,{writable:!0,readable:!1},f(this,this._forwardEnd)),i=function(){var e=t._ondrain;t._ondrain=null,e&&e()};this._unwrite&&process.nextTick(i),this._writable=e,this._writable.on("drain",i),this._unwrite=function(){t._writable.removeListener("drain",i),r()},this.uncork()},d.prototype.setReadable=function(e){if(this._unread&&this._unread(),this.destroyed){e&&e.destroy&&e.destroy();return}if(null===e||!1===e){this.push(null),this.resume();return}var t=this,r=o(e,{writable:!1,readable:!0},f(this)),s=function(){t._forward()},a=function(){t.push(null)};this._drained=!0,this._readable=e,this._readable2=e._readableState?e:new i.Readable({objectMode:!0,highWaterMark:16}).wrap(e),this._readable2.on("readable",s),this._readable2.on("end",a),this._unread=function(){t._readable2.removeListener("readable",s),t._readable2.removeListener("end",a),r()},this._forward()},d.prototype._read=function(){this._drained=!0,this._forward()},d.prototype._forward=function(){var e;if(!this._forwarding&&this._readable2&&this._drained){for(this._forwarding=!0;this._drained&&null!==(e=a(this._readable2));)this.destroyed||(this._drained=this.push(e));this._forwarding=!1}},d.prototype.destroy=function(e,t){if(t||(t=h),this.destroyed)return t(null);this.destroyed=!0;var r=this;process.nextTick(function(){r._destroy(e),t(null)})},d.prototype._destroy=function(e){if(e){var t=this._ondrain;this._ondrain=null,t?t(e):this.emit("error",e)}this._forwardDestroy&&(this._readable&&this._readable.destroy&&this._readable.destroy(),this._writable&&this._writable.destroy&&this._writable.destroy()),this.emit("close")},d.prototype._write=function(e,t,r){if(!this.destroyed){if(this._corked)return c(this,this._write.bind(this,e,t,r));if(e===u)return this._finish(r);if(!this._writable)return r();!1===this._writable.write(e)?this._ondrain=r:this.destroyed||r()}},d.prototype._finish=function(e){var t=this;this.emit("preend"),c(this,function(){var r,i;r=t._forwardEnd&&t._writable,i=function(){!1===t._writableState.prefinished&&(t._writableState.prefinished=!0),t.emit("prefinish"),c(t,e)},!r||r._writableState&&r._writableState.finished?i():r._writableState?r.end(i):(r.end(),i())})},d.prototype.end=function(e,t,r){return"function"==typeof e?this.end(null,null,e):"function"==typeof t?this.end(e,null,t):(this._ended=!0,e&&this.write(e),this._writableState.ending||this._writableState.destroyed||this.write(u),i.Writable.prototype.end.call(this,r))},e.exports=d},2913:(e,t,r)=>{"use strict";var i=r(7175);e.exports=function(e){return i(e.length)}},2965:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),r(777),r(4099),r(5267),r(1806);let i=r(3106),o=r(8611),s=r(5692),a=r(2672),u=r(15),{logScope:c}=r(6166),l=r(7016).parse,f=r(7016).format,h=c("request"),d=e=>(global.hosts||{})[e]||e,p=(e,t)=>("https:"===((void 0===t?global.proxy:t)||e).protocol?s:o).request,y=(e,t,r,i)=>{r=r||{},i=void 0===i?global.proxy:i,"content-length"in r&&delete r["content-length"];let o={};return o._headers=r,i&&"https:"===t.protocol?(o.method="CONNECT",o.headers=Object.keys(r).reduce((e,t)=>Object.assign(e,["host","user-agent"].includes(t)&&{[t]:r[t]}),{})):(o.method=e,o.headers=r),i?(o.hostname=d(i.hostname),o.port=i.port||("https:"===i.protocol?443:80),o.path="https:"===t.protocol?d(t.hostname)+":"+(t.port||443):"http://"+d(t.hostname)+t.path):(o.hostname=d(t.hostname),o.port=t.port||("https:"===t.protocol?443:80),o.path=t.path),o},g=(e,t,r,i,o,c)=>{let d=l(t),w=r||{},_=y(e,d,{host:d.hostname,accept:"application/json, text/plain, */*","accept-encoding":"gzip, deflate","accept-language":"zh-CN,zh;q=0.9","user-agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36",...w},o);return new Promise((r,l)=>{var y;h.debug(`Start requesting ${t}`);let g=p(d,o)(_),m=function(){g.destroy(new u(f(d)))};null==c||c.on(a,m),null!=(y=null==c?void 0:c.cancelled)&&y&&m(),g.setTimeout(1e4,()=>{h.warn({url:f(d)},"The request timed out, or the requester didn't handle the response."),m()}).on("response",e=>r(e)).on("connect",(t,o)=>{h.debug("received CONNECT, continuing with https.request()..."),s.request({method:e,path:d.path,headers:_._headers,socket:o,agent:!1}).on("response",e=>r(e)).on("error",e=>l(e)).end(i)}).on("error",e=>l(e)).end("CONNECT"===_.method.toUpperCase()?void 0:i)}).then(t=>{var r;if(null!=(r=null==c?void 0:c.cancelled)&&r)return Promise.reject(new u(f(d)));if([201,301,302,303,307,308].includes(t.statusCode)){let r=d.resolve(t.headers.location||d.href);return h.debug(`Redirect to ${r}`),delete w.host,g(e,r,w,i,o)}return Object.assign(t,{url:d,body:e=>m(t,e),json:()=>b(t),jsonp:()=>v(t)})})},m=(e,t)=>new Promise((t,r)=>{let i=[];e.on("data",e=>i.push(e)).on("end",()=>t(Buffer.concat(i))).on("error",e=>r(e))}).then(r=>{if(r.length)switch(e.headers["content-encoding"]){case"deflate":case"gzip":r=i.unzipSync(r);break;case"br":r=i.brotliDecompressSync(r)}return t?r:r.toString()}),b=e=>m(e,!1).then(e=>JSON.parse(e)),v=e=>m(e,!1).then(e=>JSON.parse(e.slice(e.indexOf("(")+1,-1)));g.read=m,g.create=p,g.translate=d,g.configure=y,e.exports=g},2985:(e,t,r)=>{"use strict";let i=r(9896),o=r(4434),s=r(9023).inherits,a=r(6928),u=r(7048);function c(e,t){function r(r,i){if(r){t._reopening=!1,t._writing=!1,t._opening=!1,t.sync?process.nextTick(()=>{t.listenerCount("error")>0&&t.emit("error",r)}):t.emit("error",r);return}t.fd=i,t.file=e,t._reopening=!1,t._opening=!1,t._writing=!1,t.sync?process.nextTick(()=>t.emit("ready")):t.emit("ready"),!t._reopening&&(t._writing||!(t._len>t.minLength)||t.destroyed||h(t))}t._opening=!0,t._writing=!0,t._asyncDrainScheduled=!1;let o=t.append?"a":"w";if(t.sync)try{t.mkdir&&i.mkdirSync(a.dirname(e),{recursive:!0});let s=i.openSync(e,o);r(null,s)}catch(e){throw r(e),e}else t.mkdir?i.mkdir(a.dirname(e),{recursive:!0},t=>{if(t)return r(t);i.open(e,o,r)}):i.open(e,o,r)}function l(e){if(!(this instanceof l))return new l(e);let{fd:t,dest:r,minLength:o,sync:s,append:a=!0,mkdir:p,retryEAGAIN:y}=e||{};if(t=t||r,this._bufs=[],this._len=0,this.fd=-1,this._writing=!1,this._writingBuf="",this._ending=!1,this._reopening=!1,this._asyncDrainScheduled=!1,this._hwm=Math.max(o||0,16387),this.file=null,this.destroyed=!1,this.minLength=o||0,this.sync=s||!1,this.append=a||!1,this.retryEAGAIN=y||(()=>!0),this.mkdir=p||!1,"number"==typeof t)this.fd=t,process.nextTick(()=>this.emit("ready"));else if("string"==typeof t)c(t,this);else throw Error("SonicBoom supports only file descriptors and files");if(this.minLength>=0x1000000)throw Error("minLength should be smaller than MAX_WRITE (16777216)");this.release=(e,t)=>{if(e){if("EAGAIN"===e.code&&this.retryEAGAIN(e,this._writingBuf.length,this._len-this._writingBuf.length))if(this.sync)try{u(100),this.release(void 0,0)}catch(e){this.release(e)}else setTimeout(()=>{i.write(this.fd,this._writingBuf,"utf8",this.release)},100);else this._writing=!1,this.emit("error",e);return}if(this._len-=t,this._writingBuf=this._writingBuf.slice(t),this._writingBuf.length){if(!this.sync)return void i.write(this.fd,this._writingBuf,"utf8",this.release);try{do{let e=i.writeSync(this.fd,this._writingBuf,"utf8");this._len-=e,this._writingBuf=this._writingBuf.slice(e)}while(this._writingBuf)}catch(e){this.release(e);return}}let r=this._len;this._reopening?(this._writing=!1,this._reopening=!1,this.reopen()):r>this.minLength?h(this):this._ending?r>0?h(this):(this._writing=!1,d(this)):(this._writing=!1,this.sync?this._asyncDrainScheduled||(this._asyncDrainScheduled=!0,process.nextTick(f,this)):this.emit("drain"))},this.on("newListener",function(e){"drain"===e&&(this._asyncDrainScheduled=!1)})}function f(e){e.listenerCount("drain")>0&&(e._asyncDrainScheduled=!1,e.emit("drain"))}function h(e){let t=e.release;if(e._writing=!0,e._writingBuf=e._writingBuf||e._bufs.shift(),e.sync)try{let r=i.writeSync(e.fd,e._writingBuf,"utf8");t(null,r)}catch(e){t(e)}else i.write(e.fd,e._writingBuf,"utf8",t)}function d(e){if(-1===e.fd)return void e.once("ready",d.bind(null,e));i.close(e.fd,t=>{if(t)return void e.emit("error",t);e._ending&&!e._writing&&e.emit("finish"),e.emit("close")}),e.destroyed=!0,e._bufs=[]}s(l,o),l.prototype.write=function(e){if(this.destroyed)throw Error("SonicBoom destroyed");let t=this._len+e.length,r=this._bufs;return!this._writing&&t>0x1000000?r.push(e):0===r.length?r[0]=""+e:r[r.length-1]+=e,this._len=t,!this._writing&&this._len>=this.minLength&&h(this),this._len<this._hwm},l.prototype.flush=function(){if(this.destroyed)throw Error("SonicBoom destroyed");this._writing||this.minLength<=0||(0===this._bufs.length&&this._bufs.push(""),h(this))},l.prototype.reopen=function(e){if(this.destroyed)throw Error("SonicBoom destroyed");if(this._opening)return void this.once("ready",()=>{this.reopen(e)});if(this._ending)return;if(!this.file)throw Error("Unable to reopen a file descriptor, you must pass a file to SonicBoom");if(this._reopening=!0,this._writing)return;let t=this.fd;this.once("ready",()=>{t!==this.fd&&i.close(t,e=>{if(e)return this.emit("error",e)})}),c(e||this.file,this)},l.prototype.end=function(){if(this.destroyed)throw Error("SonicBoom destroyed");if(this._opening)return void this.once("ready",()=>{this.end()});!this._ending&&(this._ending=!0,this._writing||(this._len>0&&this.fd>=0?h(this):d(this)))},l.prototype.flushSync=function(){if(this.destroyed)throw Error("SonicBoom destroyed");if(this.fd<0)throw Error("sonic boom is not ready yet");for(!this._writing&&this._writingBuf.length>0&&(this._bufs.unshift(this._writingBuf),this._writingBuf="");this._bufs.length;){let e=this._bufs[0];try{this._len-=i.writeSync(this.fd,e,"utf8"),this._bufs.shift()}catch(t){if("EAGAIN"!==t.code||!this.retryEAGAIN(t,e.length,this._len-e.length))throw t;u(100)}}},l.prototype.destroy=function(){this.destroyed||d(this)},l.SonicBoom=l,l.default=l,e.exports=l},3049:e=>{e.exports=function(e){var t,r=e._readableState;return r?r.objectMode||"number"==typeof e._duplexState?e.read():e.read((t=r).buffer.length?t.buffer.head?t.buffer.head.data.length:t.buffer[0].length:t.length):null}},3060:(e,t,r)=>{"use strict";r(6535)},3081:(e,t,r)=>{try{var i=r(9023);if("function"!=typeof i.inherits)throw"";e.exports=i.inherits}catch(t){e.exports=r(3522)}},3106:e=>{"use strict";e.exports=require("zlib")},3172:(e,t,r)=>{"use strict";var i=r(697),o=r(1196),s=r(1999),a=r(5449);i({target:"Set",proto:!0,real:!0,forced:!0},{union:function(e){return o(a,this,s(e))}})},3186:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),r(777),r(4914),e.exports=(e,t)=>{let{duration:r}=t,i=e.slice(0,5).find(e=>e.duration&&5e3>Math.abs(e.duration-r));return i||e[0]},e.exports.ENABLE_FLAC="true"===(process.env.ENABLE_FLAC||"").toLowerCase()},3193:e=>{"use strict";e.exports=require("string_decoder")},3354:(e,t,r)=>{"use strict";var i=r(6078),o=r(8295);e.exports=!i(function(){var e=Error("a");return!("stack"in e)||(Object.defineProperty(e,"stack",o(1,7)),7!==e.stack)})},3367:(e,t,r)=>{"use strict";var i=r(697),o=r(8173),s=r(5773),a=r(9900),u=r(6790),c=o([].join),l=o([].push);i({target:"Set",proto:!0,real:!0,forced:!0},{join:function(e){var t=s(this),r=void 0===e?",":u(e),i=[];return a(t,function(e){l(i,e)}),c(i,r)}})},3416:(e,t,r)=>{"use strict";var i=r(697),o=r(5869),s=r(2675),a=r(6465),u=TypeError,c=a.get,l=a.has,f=a.set;i({target:"Map",proto:!0,real:!0,forced:!0},{update:function(e,t){var r=s(this),i=arguments.length;o(t);var a=l(r,e);if(!a&&i<3)throw new u("Updating absent value");var h=a?c(r,e):o(i>2?arguments[2]:void 0)(e,r);return f(r,e,t(h,e,r)),r}})},3480:e=>{"use strict";e.exports=require("querystring")},3509:(e,t,r)=>{"use strict";var i=r(2025),o=r(6880),s=i.WeakMap;e.exports=o(s)&&/native code/.test(String(s))},3522:e=>{"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},3531:(e,t,r)=>{"use strict";var i=r(6880);e.exports=function(e){return"object"==typeof e?null!==e:i(e)}},3543:(e,t,r)=>{"use strict";var i=r(697),o=r(1196),s=r(1999),a=r(7044);i({target:"Set",proto:!0,real:!0,forced:!0},{isSupersetOf:function(e){return o(a,this,s(e))}})},3557:(e,t,r)=>{"use strict";var i=r(8585),o=r(8142),s=r(8295);e.exports=function(e,t,r){i?o.f(e,t,s(0,r)):e[t]=r}},3561:(e,t,r)=>{"use strict";var i=r(8034),o=TypeError;e.exports=function(e){if(i(e))throw new o("Can't call method on "+e);return e}},3567:(e,t,r)=>{"use strict";var i=r(6724),o=Math.max,s=Math.min;e.exports=function(e,t){var r=i(e);return r<0?o(r+t,0):s(r,t)}},3581:(e,t,r)=>{"use strict";function i(e){var t=this;this.next=null,this.entry=null,this.finish=function(){var r=t,i=e,o=r.entry;for(r.entry=null;o;){var s=o.callback;i.pendingcb--,s(void 0),o=o.next}i.corkedRequestsFree.next=r}}e.exports=O,O.WritableState=E;var o,s,a={deprecate:r(2664)},u=r(5251),c=r(181).Buffer,l=global.Uint8Array||function(){},f=r(849),h=r(6906).getHighWaterMark,d=r(8396).F,p=d.ERR_INVALID_ARG_TYPE,y=d.ERR_METHOD_NOT_IMPLEMENTED,g=d.ERR_MULTIPLE_CALLBACK,m=d.ERR_STREAM_CANNOT_PIPE,b=d.ERR_STREAM_DESTROYED,v=d.ERR_STREAM_NULL_VALUES,w=d.ERR_STREAM_WRITE_AFTER_END,_=d.ERR_UNKNOWN_ENCODING,S=f.errorOrDestroy;function x(){}function E(e,t,s){o=o||r(5535),e=e||{},"boolean"!=typeof s&&(s=t instanceof o),this.objectMode=!!e.objectMode,s&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=h(this,e,"writableHighWaterMark",s),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var a=!1===e.decodeStrings;this.decodeStrings=!a,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,i=r.sync,o=r.writecb;if("function"!=typeof o)throw new g;if(r.writing=!1,r.writecb=null,r.length-=r.writelen,r.writelen=0,t)--r.pendingcb,i?(process.nextTick(o,t),process.nextTick(P,e,r),e._writableState.errorEmitted=!0,S(e,t)):(o(t),e._writableState.errorEmitted=!0,S(e,t),P(e,r));else{var s=R(r)||e.destroyed;s||r.corked||r.bufferProcessing||!r.bufferedRequest||T(e,r),i?process.nextTick(k,e,r,s,o):k(e,r,s,o)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new i(this)}r(3081)(O,u),E.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t};try{Object.defineProperty(E.prototype,"buffer",{get:a.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}function O(e){var t=this instanceof(o=o||r(5535));if(!t&&!s.call(O,this))return new O(e);this._writableState=new E(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),u.call(this)}function j(e,t,r,i,o,s,a){t.writelen=i,t.writecb=a,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new b("write")):r?e._writev(o,t.onwrite):e._write(o,s,t.onwrite),t.sync=!1}function k(e,t,r,i){var o,s;r||(o=e,0===(s=t).length&&s.needDrain&&(s.needDrain=!1,o.emit("drain"))),t.pendingcb--,i(),P(e,t)}function T(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var o=Array(t.bufferedRequestCount),s=t.corkedRequestsFree;s.entry=r;for(var a=0,u=!0;r;)o[a]=r,r.isBuf||(u=!1),r=r.next,a+=1;o.allBuffers=u,j(e,t,!0,t.length,o,"",s.finish),t.pendingcb++,t.lastBufferedRequest=null,s.next?(t.corkedRequestsFree=s.next,s.next=null):t.corkedRequestsFree=new i(t),t.bufferedRequestCount=0}else{for(;r;){var c=r.chunk,l=r.encoding,f=r.callback,h=t.objectMode?1:c.length;if(j(e,t,!1,h,c,l,f),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function R(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function M(e,t){e._final(function(r){t.pendingcb--,r&&S(e,r),t.prefinished=!0,e.emit("prefinish"),P(e,t)})}function P(e,t){var r=R(t);if(r&&(t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,process.nextTick(M,e,t))),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var i=e._readableState;(!i||i.autoDestroy&&i.endEmitted)&&e.destroy()}return r}"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(s=Function.prototype[Symbol.hasInstance],Object.defineProperty(O,Symbol.hasInstance,{value:function(e){return!!s.call(this,e)||this===O&&e&&e._writableState instanceof E}})):s=function(e){return e instanceof this},O.prototype.pipe=function(){S(this,new m)},O.prototype.write=function(e,t,r){var i,o,s,a,u,f,h,d=this._writableState,y=!1,g=!d.objectMode&&(i=e,c.isBuffer(i)||i instanceof l);return(g&&!c.isBuffer(e)&&(o=e,e=c.from(o)),"function"==typeof t&&(r=t,t=null),g?t="buffer":t||(t=d.defaultEncoding),"function"!=typeof r&&(r=x),d.ending)?(s=r,S(this,a=new w),process.nextTick(s,a)):(g||(u=e,f=r,null===u?h=new v:"string"==typeof u||d.objectMode||(h=new p("chunk",["string","Buffer"],u)),!h||(S(this,h),process.nextTick(f,h),0)))&&(d.pendingcb++,y=function(e,t,r,i,o,s){if(!r){var a,u,l=(a=i,u=o,t.objectMode||!1===t.decodeStrings||"string"!=typeof a||(a=c.from(a,u)),a);i!==l&&(r=!0,o="buffer",i=l)}var f=t.objectMode?1:i.length;t.length+=f;var h=t.length<t.highWaterMark;if(h||(t.needDrain=!0),t.writing||t.corked){var d=t.lastBufferedRequest;t.lastBufferedRequest={chunk:i,encoding:o,isBuf:r,callback:s,next:null},d?d.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else j(e,t,!1,f,i,o,s);return h}(this,d,g,e,t,r)),y},O.prototype.cork=function(){this._writableState.corked++},O.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||T(this,e))},O.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new _(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(O.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(O.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),O.prototype._write=function(e,t,r){r(new y("_write()"))},O.prototype._writev=null,O.prototype.end=function(e,t,r){var i,o,s,a=this._writableState;return"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),a.corked&&(a.corked=1,this.uncork()),a.ending||(i=this,o=a,s=r,o.ending=!0,P(i,o),s&&(o.finished?process.nextTick(s):i.once("finish",s)),o.ended=!0,i.writable=!1),this},Object.defineProperty(O.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(O.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),O.prototype.destroy=f.destroy,O.prototype._undestroy=f.undestroy,O.prototype._destroy=function(e,t){t(e)}},3621:(e,t,r)=>{"use strict";r(9988)},3695:(e,t,r)=>{"use strict";var i=r(8585),o=r(6078);e.exports=i&&o(function(){return 42!==Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype})},3710:(e,t,r)=>{"use strict";let i=Symbol.for("pino.metadata"),o=r(202),s=r(2896);function a(e,t){process.nextTick(t,e)}e.exports=function(e,t={}){let r="lines"===t.parse,u="function"==typeof t.parseLine?t.parseLine:JSON.parse,c=t.close||a,l=o(function(e){let t;try{t=u(e)}catch(t){this.emit("unknown",e,t);return}return null===t?void this.emit("unknown",e,"Null value ignored"):("object"!=typeof t&&(t={data:t,time:Date.now()}),l[i]&&(l.lastTime=t.time,l.lastLevel=t.level,l.lastObj=t),r)?e:t},{autoDestroy:!0});l._destroy=function(e,t){let r=c(e,t);r&&"function"==typeof r.then&&r.then(t,t)},!1!==t.metadata&&(l[i]=!0,l.lastTime=0,l.lastLevel=0,l.lastObj=null);let f=e(l);if(f&&"function"==typeof f.catch)f.catch(e=>{l.destroy(e)}),f=null;else if(t.enablePipelining&&f)return s(l,f,{objectMode:!0});return l}},3746:(e,t,r)=>{"use strict";var i=r(5653),o=r(6880),s=r(9061),a=r(8078)("toStringTag"),u=Object,c="Arguments"===s(function(){return arguments}()),l=function(e,t){try{return e[t]}catch(e){}};e.exports=i?s:function(e){var t,r,i;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(r=l(t=u(e),a))?r:c?s(t):"Object"===(i=s(t))&&o(t.callee)?"Arguments":i}},3806:(e,t,r)=>{"use strict";var i=r(4554);e.exports=function(e,t){return i[e]||(i[e]=t||{})}},3845:(e,t,r)=>{"use strict";var i=r(4689),o=r(1196),s=r(4526),a=r(8498),u=r(8550),c=r(2913),l=r(6814),f=r(9058),h=r(574),d=r(9384),p=TypeError,y=function(e,t){this.stopped=e,this.result=t},g=y.prototype;e.exports=function(e,t,r){var m,b,v,w,_,S,x,E=r&&r.that,O=!!(r&&r.AS_ENTRIES),j=!!(r&&r.IS_RECORD),k=!!(r&&r.IS_ITERATOR),T=!!(r&&r.INTERRUPTED),R=i(t,E),M=function(e){return m&&d(m,"normal"),new y(!0,e)},P=function(e){return O?(s(e),T?R(e[0],e[1],M):R(e[0],e[1])):T?R(e,M):R(e)};if(j)m=e.iterator;else if(k)m=e;else{if(!(b=h(e)))throw new p(a(e)+" is not iterable");if(u(b)){for(v=0,w=c(e);w>v;v++)if((_=P(e[v]))&&l(g,_))return _;return new y(!1)}m=f(e,b)}for(S=j?e.next:m.next;!(x=o(S,m)).done;){try{_=P(x.value)}catch(e){d(m,"throw",e)}if("object"==typeof _&&_&&l(g,_))return _}return new y(!1)}},3892:(e,t,r)=>{"use strict";var i,o,s=r(2025),a=r(1576),u=s.process,c=s.Deno,l=u&&u.versions||c&&c.version,f=l&&l.v8;f&&(o=(i=f.split("."))[0]>0&&i[0]<4?1:+(i[0]+i[1])),!o&&a&&(!(i=a.match(/Edge\/(\d+)/))||i[1]>=74)&&(i=a.match(/Chrome\/(\d+)/))&&(o=+i[1]),e.exports=o},4025:(e,t,r)=>{"use strict";var i=r(697),o=r(1196),s=r(1999),a=r(7854);i({target:"Set",proto:!0,real:!0,forced:!0},{isDisjointFrom:function(e){return o(a,this,s(e))}})},4037:e=>{e.exports=function e(t,r){if(t&&r)return e(t)(r);if("function"!=typeof t)throw TypeError("need wrapper function");return Object.keys(t).forEach(function(e){i[e]=t[e]}),i;function i(){for(var e=Array(arguments.length),r=0;r<e.length;r++)e[r]=arguments[r];var i=t.apply(this,e),o=e[e.length-1];return"function"==typeof i&&i!==o&&Object.keys(o).forEach(function(e){i[e]=o[e]}),i}}},4045:e=>{"use strict";let t="undefined"!=typeof Buffer,r=/"(?:_|\\u005[Ff])(?:_|\\u005[Ff])(?:p|\\u0070)(?:r|\\u0072)(?:o|\\u006[Ff])(?:t|\\u0074)(?:o|\\u006[Ff])(?:_|\\u005[Ff])(?:_|\\u005[Ff])"\s*:/,i=/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/;function o(e,o,a){null==a&&(null!==o&&"object"==typeof o?(a=o,o=void 0):a={});let u=a.protoAction||"error",c=a.constructorAction||"error";t&&Buffer.isBuffer(e)&&(e=e.toString()),e&&65279===e.charCodeAt(0)&&(e=e.slice(1));let l=JSON.parse(e,o);if("ignore"===u&&"ignore"===c||null===l||"object"!=typeof l)return l;if("ignore"!==u&&"ignore"!==c){if(!1===r.test(e)&&!1===i.test(e))return l}else if("ignore"!==u&&"ignore"===c){if(!1===r.test(e))return l}else if(!1===i.test(e))return l;return s(l,{protoAction:u,constructorAction:c}),l}function s(e,{protoAction:t="error",constructorAction:r="error"}={}){let i=[e];for(;i.length;){let e=i;for(let o of(i=[],e)){if("ignore"!==t&&Object.prototype.hasOwnProperty.call(o,"__proto__")){if("error"===t)throw SyntaxError("Object contains forbidden prototype property");delete o.__proto__}if("ignore"!==r&&Object.prototype.hasOwnProperty.call(o,"constructor")&&Object.prototype.hasOwnProperty.call(o.constructor,"prototype")){if("error"===r)throw SyntaxError("Object contains forbidden prototype property");delete o.constructor}for(let e in o){let t=o[e];t&&"object"==typeof t&&i.push(o[e])}}}}e.exports={parse:o,scan:s,safeParse:function(e,t){try{return o(e,t)}catch(e){return null}}}},4068:(e,t,r)=>{"use strict";e.exports=!r(6078)(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype})},4099:(e,t,r)=>{"use strict";r(2262)},4164:(e,t,r)=>{"use strict";var i=r(8585),o=r(8142),s=r(8295);e.exports=i?function(e,t,r){return o.f(e,t,s(1,r))}:function(e,t,r){return e[t]=r,e}},4214:(e,t,r)=>{"use strict";var i=r(3746),o=r(2870),s=r(8034),a=r(8078),u=r(6728),c=a("iterator"),l=Object;e.exports=function(e){if(s(e))return!1;var t=l(e);return void 0!==t[c]||"@@iterator"in t||o(u,i(t))}},4249:e=>{"use strict";e.exports={DATE_FORMAT:"yyyy-mm-dd HH:MM:ss.l o",ERROR_LIKE_KEYS:["err","error"],MESSAGE_KEY:"msg",LEVEL_KEY:"level",LEVEL_LABEL:"levelLabel",TIMESTAMP_KEY:"time",LEVELS:{default:"USERLVL",60:"FATAL",50:"ERROR",40:"WARN",30:"INFO",20:"DEBUG",10:"TRACE"},LEVEL_NAMES:{fatal:60,error:50,warn:40,info:30,debug:20,trace:10},LOGGER_KEYS:["pid","hostname","name","level","time","timestamp","caller"]}},4264:e=>{"use strict";e.exports=function(e){try{var t=new Set,r=t[e]({size:0,has:function(){return!0},keys:function(){return Object.defineProperty({},"next",{get:function(){return t.clear(),t.add(4),function(){return{done:!0}}}})}});return 1===r.size&&4===r.values().next().value}catch(e){return!1}}},4285:(e,t,r)=>{"use strict";var i=r(8173),o=r(8348),s=r(6465),a=s.Map,u=s.proto,c=i(u.forEach),l=i(u.entries),f=l(new a).next;e.exports=function(e,t,r){return r?o({iterator:l(e),next:f},function(e){return t(e[1],e[0])}):c(e,t)}},4296:(e,t,r)=>{"use strict";var i=r(4526),o=r(9384);e.exports=function(e,t,r,s){try{return s?t(i(r)[0],r[1]):t(r)}catch(t){o(e,"throw",t)}}},4298:(e,t,r)=>{"use strict";var i=r(2025),o=r(3531),s=i.document,a=o(s)&&o(s.createElement);e.exports=function(e){return a?s.createElement(e):{}}},4314:(e,t,r)=>{"use strict";var i=r(4164),o=r(992),s=r(3354),a=Error.captureStackTrace;e.exports=function(e,t,r,u){s&&(a?a(e,t):i(e,"stack",o(r,u)))}},4337:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),r(7784),r(2448),r(1202),r(8795),r(8422),r(4500),r(488),r(9158),r(1808),r(1933),r(1501),r(8255),r(6925),r(3416),r(777),r(5410),r(8528),r(8222),r(8727),r(2862),r(3621),r(2122),r(3060),r(8770),r(4850),r(2552),r(2736),r(9437),r(8096),r(8966),r(4025),r(5590),r(3543),r(3367),r(9193),r(5921),r(5239),r(5962),r(3172);let{EventEmitter:i}=r(4434),{logScope:o}=r(6166),s=o("cache"),a={CLEANUP:"cs@cleanup"};class u extends i{id="Default Cache Storage";cacheMap=new Map;aliveDuration=18e5;constructor(e){super(),e&&(this.id=e),this.on(a.CLEANUP,async()=>this.removeExpiredCache())}get WillExpireAt(){return Date.now()+this.aliveDuration}getLoggerContext(e={}){return{...e,cacheStorageId:this.id}}removeExpiredCache(){s.debug(this.getLoggerContext(),"Cleaning up the expired caches..."),this.cacheMap.forEach((e,t)=>{e.expireAt<=Date.now()&&this.cacheMap.delete(t)})}async cache(e,t,r){if("true"===process.env.NO_CACHE)return t();this.emit(a.CLEANUP);let i=this.cacheMap.get(e),o="object"==typeof e?"Something":e,u=this.getLoggerContext({logKey:o});if(i)return s.debug(u,`${o} hit!`),i.data;s.debug(u,`${o} did not hit. Storing the execution result...`);let c=await t();return this.cacheMap.set(e,{data:c,expireAt:new Date(r||this.WillExpireAt)}),c}}class c{static instance=void 0;cacheStorages=new Set;constructor(){}static getInstance(){return c.instance||(c.instance=new c),c.instance}cleanup(){this.cacheStorages.forEach(e=>e.removeExpiredCache())}}let l=c.getInstance();e.exports={CacheStorage:u,CacheStorageEvents:a,CacheStorageGroup:c,getManagedCacheStorage:function(e){let t=new u(e);return l.cacheStorages.add(t),t}}},4359:(e,t,r)=>{"use strict";var i=r(697),o=r(1196),s=r(3845),a=r(5869),u=r(4526),c=r(6718),l=r(9384),f=r(8918)("find",TypeError);i({target:"Iterator",proto:!0,real:!0,forced:f},{find:function(e){u(this);try{a(e)}catch(e){l(this,"throw",e)}if(f)return o(f,this,e);var t=c(this),r=0;return s(t,function(t,i){if(e(t,r++))return i(t)},{IS_RECORD:!0,INTERRUPTED:!0}).result}})},4429:(e,t,r)=>{"use strict";e.exports=r(2436)&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},4434:e=>{"use strict";e.exports=require("events")},4500:(e,t,r)=>{"use strict";var i=r(697),o=r(4689),s=r(2675),a=r(4285);i({target:"Map",proto:!0,real:!0,forced:!0},{findKey:function(e){var t=s(this),r=o(e,arguments.length>1?arguments[1]:void 0),i=a(t,function(e,i){if(r(e,i,t))return{key:i}},!0);return i&&i.key}})},4526:(e,t,r)=>{"use strict";var i=r(3531),o=String,s=TypeError;e.exports=function(e){if(i(e))return e;throw new s(o(e)+" is not an object")}},4554:(e,t,r)=>{"use strict";var i=r(2250),o=r(2025),s=r(722),a="__core-js_shared__",u=e.exports=o[a]||s(a,{});(u.versions||(u.versions=[])).push({version:"3.45.1",mode:i?"pure":"global",copyright:"© 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.45.1/LICENSE",source:"https://github.com/zloirock/core-js"})},4563:(e,t,r)=>{"use strict";var i=r(1196),o=r(6880),s=r(3531),a=TypeError;e.exports=function(e,t){var r,u;if("string"===t&&o(r=e.toString)&&!s(u=i(r,e))||o(r=e.valueOf)&&!s(u=i(r,e))||"string"!==t&&o(r=e.toString)&&!s(u=i(r,e)))return u;throw new a("Can't convert object to primitive value")}},4649:(e,t,r)=>{"use strict";var i=r(1262),o=r(8142);e.exports=function(e,t,r){return r.get&&i(r.get,t,{getter:!0}),r.set&&i(r.set,t,{setter:!0}),o.f(e,t,r)}},4689:(e,t,r)=>{"use strict";var i=r(6799),o=r(5869),s=r(1651),a=i(i.bind);e.exports=function(e,t){return o(e),void 0===t?e:s?a(e,t):function(){return e.apply(t,arguments)}}},4690:(e,t,r)=>{"use strict";var i=r(8381),o=r(3531),s=r(3561),a=r(9853);e.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,r={};try{(e=i(Object.prototype,"__proto__","set"))(r,[]),t=r instanceof Array}catch(e){}return function(r,i){return s(r),a(i),o(r)&&(t?e(r,i):r.__proto__=i),r}}():void 0)},4833:(e,t,r)=>{"use strict";var i=r(8173),o=r(6880),s=r(4554),a=i(Function.toString);o(s.inspectSource)||(s.inspectSource=function(e){return a(e)}),e.exports=s.inspectSource},4850:(e,t,r)=>{"use strict";var i=r(697),o=r(5773),s=r(487).remove;i({target:"Set",proto:!0,real:!0,forced:!0},{deleteAll:function(){for(var e,t=o(this),r=!0,i=0,a=arguments.length;i<a;i++)e=s(t,arguments[i]),r=r&&e;return!!r}})},4914:(e,t,r)=>{"use strict";r(4359)},5032:(e,t,r)=>{"use strict";var i=r(3561),o=Object;e.exports=function(e){return o(i(e))}},5092:e=>{"use strict";e.exports=function(e,t){return e===t||e!=e&&t!=t}},5117:e=>{"use strict";e.exports=function(e){let{secret:t,censor:r,compileRestore:i,serialize:o,groupRedact:s,nestedRedact:a,wildcards:u,wcLen:c}=e,l=[{secret:t,censor:r,compileRestore:i}];return!1!==o&&l.push({serialize:o}),c>0&&l.push({groupRedact:s,nestedRedact:a,wildcards:u,wcLen:c}),Object.assign(...l)}},5212:(e,t,r)=>{"use strict";var i=r(8585),o=r(1196),s=r(1852),a=r(8295),u=r(1512),c=r(148),l=r(2870),f=r(5698),h=Object.getOwnPropertyDescriptor;t.f=i?h:function(e,t){if(e=u(e),t=c(t),f)try{return h(e,t)}catch(e){}if(l(e,t))return a(!o(s.f,e,t),e[t])}},5228:(e,t,r)=>{"use strict";var i=r(7776),o=r(8173),s=r(833),a=r(9232),u=r(4526),c=o([].concat);e.exports=i("Reflect","ownKeys")||function(e){var t=s.f(u(e)),r=a.f;return r?c(t,r(e)):t}},5239:(e,t,r)=>{"use strict";var i=r(697),o=r(4689),s=r(5773),a=r(9900);i({target:"Set",proto:!0,real:!0,forced:!0},{some:function(e){var t=s(this),r=o(e,arguments.length>1?arguments[1]:void 0);return!0===a(t,function(e){if(r(e,e,t))return!0},!0)}})},5251:(e,t,r)=>{e.exports=r(2203)},5262:(e,t,r)=>{"use strict";let{EventEmitter:i}=r(4434),o=r(361),s=r(1517),a=r(617),{lsCacheSym:u,levelValSym:c,setLevelSym:l,getLevelSym:f,chindingsSym:h,parsedChindingsSym:d,mixinSym:p,asJsonSym:y,writeSym:g,mixinMergeStrategySym:m,timeSym:b,timeSliceIndexSym:v,streamSym:w,serializersSym:_,formattersSym:S,useOnlyCustomLevelsSym:x,needsMetadataGsym:E,redactFmtSym:O,stringifySym:j,formatOptsSym:k,stringifiersSym:T}=r(37),{getLevel:R,setLevel:M,isLevelEnabled:P,mappings:L,initialLsCache:A,genLsCache:N,assertNoLevelCollisions:D}=r(2129),{asChindings:C,asJson:I,buildFormatters:B,stringify:$}=r(711),{version:U}=r(6011),q=r(2205),F={constructor:class{},child:function(e,t){if(!e)throw Error("missing bindings for child Pino");t=t||{};let r=this[_],i=this[S],o=Object.create(this);if(!0===e.hasOwnProperty("serializers")&&(a.emit("PINODEP004"),t.serializers=e.serializers),!0===e.hasOwnProperty("formatters")&&(a.emit("PINODEP005"),t.formatters=e.formatters),!0===e.hasOwnProperty("customLevels")&&(a.emit("PINODEP006"),t.customLevels=e.customLevels),!0===e.hasOwnProperty("level")&&(a.emit("PINODEP007"),t.level=e.level),!0===t.hasOwnProperty("serializers")){for(let e in o[_]=Object.create(null),r)o[_][e]=r[e];let e=Object.getOwnPropertySymbols(r);for(var s=0;s<e.length;s++){let t=e[s];o[_][t]=r[t]}for(let e in t.serializers)o[_][e]=t.serializers[e];let i=Object.getOwnPropertySymbols(t.serializers);for(var u=0;u<i.length;u++){let e=i[u];o[_][e]=t.serializers[e]}}else o[_]=r;if(t.hasOwnProperty("formatters")){let{level:e,bindings:r,log:s}=t.formatters;o[S]=B(e||i.level,r||W,s||i.log)}else o[S]=B(i.level,W,i.log);if(!0===t.hasOwnProperty("customLevels")&&(D(this.levels,t.customLevels),o.levels=L(t.customLevels,o[x]),N(o)),"object"==typeof t.redact&&null!==t.redact||Array.isArray(t.redact)){o.redact=t.redact;let e=q(o.redact,$),r={stringify:e[O]};o[j]=$,o[T]=e,o[k]=r}o[h]=C(o,e);let c=t.level||this.level;return o[l](c),o},bindings:function(){let e=this[h],t=JSON.parse(`{${e.substr(1)}}`);return delete t.pid,delete t.hostname,t},setBindings:function(e){let t=C(this,e);this[h]=t,delete this[d]},flush:function(){let e=this[w];"flush"in e&&e.flush()},isLevelEnabled:P,version:U,get level(){return this[f]()},set level(lvl){this[l](lvl)},get levelVal(){return this[c]},set levelVal(n){throw Error("levelVal is read-only")},[u]:A,[g]:function(e,t,r){let i,a=this[b](),u=this[p],c=this[m]||z,l=e instanceof Error;null==e?i=u?u({}):{}:(i=c(e,u?u(e):{}),!t&&l&&(t=e.message),l&&(i.stack=e.stack,i.type||(i.type="Error")));let f=this[y](i,t,r,a),h=this[w];!0===h[E]&&(h.lastLevel=r,h.lastObj=i,h.lastMsg=t,h.lastTime=a.slice(this[v]),h.lastLogger=this),h instanceof o?h.write(f):h.write(s(f))},[y]:I,[f]:R,[l]:M};Object.setPrototypeOf(F,i.prototype),e.exports=function(){return Object.create(F)};let W=e=>e;function z(e,t){return Object.assign(t,e)}},5267:(e,t,r)=>{"use strict";var i=r(697),o=r(5032),s=r(2913),a=r(2732),u=r(9534);i({target:"Array",proto:!0,arity:1,forced:r(6078)(function(){return 0x100000001!==[].push.call({length:0x100000000},1)})||!function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(e){return e instanceof TypeError}}()},{push:function(e){var t=o(this),r=s(t),i=arguments.length;u(r+i);for(var c=0;c<i;c++)t[r]=arguments[c],r++;return a(t,r),r}})},5317:e=>{"use strict";e.exports=require("child_process")},5319:(e,t,r)=>{"use strict";let i=r(5317),{logScope:o}=r(6166),s=r(1828),a=o("spawn");e.exports={spawnStdout:async function(e,t=[]){return new Promise((r,o)=>{let u=0,c=0,l=Buffer.alloc(5e6),f=Buffer.alloc(5e6),h=i.spawn(e,t);h.on("spawn",()=>{a.info(`running ${e} ${t.join(" ")}`)}),h.on("error",e=>o(e)),h.on("close",t=>{0!==t?o(new s(e,t)):(a.debug(`process ${e} exited successfully`),r({stdout:l.slice(0,u),stderr:f.slice(0,c)}))}),h.stdout.on("data",e=>{u+=e.copy(l,u)}),h.stderr.on("data",t=>{a.warn(`[${e}][stderr] ${t}`),c+=t.copy(f,c)})})}}},5369:(e,t,r)=>{"use strict";var i=r(6880),o=r(8142),s=r(1262),a=r(722);e.exports=function(e,t,r,u){u||(u={});var c=u.enumerable,l=void 0!==u.name?u.name:t;if(i(r)&&s(r,l,u),u.global)c?e[t]=r:a(t,r);else{try{u.unsafe?e[t]&&(c=!0):delete e[t]}catch(e){}c?e[t]=r:o.f(e,t,{value:r,enumerable:!1,configurable:!u.nonConfigurable,writable:!u.nonWritable})}return e}},5374:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),r(1806);let{getManagedCacheStorage:i}=r(4337),{logScope:o}=r(6166),s=r(8696),a=r(6587),{spawnStdout:u}=r(5319),c=o("provider/youtube-dl");async function l(e){try{let{stdout:t}=await u("youtube-dl",e),r=JSON.parse(t.toString());if("object"==typeof r&&"string"==typeof r.id&&"string"==typeof r.url)return r;throw new s(r)}catch(e){if(e&&"ENOENT"===e.code)throw new a;throw e}}let f=async e=>{let t,{url:r}=await l((t=e.keyword,["-f","140","--dump-json",`ytsearch1:${t}`]));return r},h=i("youtube-dl");e.exports={check:e=>h.cache(e,()=>f(e)).catch(e=>{throw e&&c.error(e),e})}},5402:(e,t,r)=>{"use strict";var i;function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}!function(s){var a,u,c,l=arguments,f=(a=/d{1,4}|D{3,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|W{1,2}|[LlopSZN]|"[^"]*"|'[^']*'/g,u=/\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g,c=/[^-+\dA-Z]/g,function(e,t,r,i){if(1!==l.length||"string"!==g(e)||/\d/.test(e)||(t=e,e=void 0),(e=e||0===e?e:new Date)instanceof Date||(e=new Date(e)),isNaN(e))throw TypeError("Invalid date");var o=(t=String(f.masks[t]||t||f.masks.default)).slice(0,4);("UTC:"===o||"GMT:"===o)&&(t=t.slice(4),r=!0,"GMT:"===o&&(i=!0));var s=function(){return r?"getUTC":"get"},m=function(){return e[s()+"Date"]()},b=function(){return e[s()+"Day"]()},v=function(){return e[s()+"Month"]()},w=function(){return e[s()+"FullYear"]()},_=function(){return e[s()+"Hours"]()},S=function(){return e[s()+"Minutes"]()},x=function(){return e[s()+"Seconds"]()},E=function(){return e[s()+"Milliseconds"]()},O=function(){return r?0:e.getTimezoneOffset()},j=function(){return p(e)},k={d:function(){return m()},dd:function(){return h(m())},ddd:function(){return f.i18n.dayNames[b()]},DDD:function(){return d({y:w(),m:v(),d:m(),_:s(),dayName:f.i18n.dayNames[b()],short:!0})},dddd:function(){return f.i18n.dayNames[b()+7]},DDDD:function(){return d({y:w(),m:v(),d:m(),_:s(),dayName:f.i18n.dayNames[b()+7]})},m:function(){return v()+1},mm:function(){return h(v()+1)},mmm:function(){return f.i18n.monthNames[v()]},mmmm:function(){return f.i18n.monthNames[v()+12]},yy:function(){return String(w()).slice(2)},yyyy:function(){return h(w(),4)},h:function(){return _()%12||12},hh:function(){return h(_()%12||12)},H:function(){return _()},HH:function(){return h(_())},M:function(){return S()},MM:function(){return h(S())},s:function(){return x()},ss:function(){return h(x())},l:function(){return h(E(),3)},L:function(){return h(Math.floor(E()/10))},t:function(){return 12>_()?f.i18n.timeNames[0]:f.i18n.timeNames[1]},tt:function(){return 12>_()?f.i18n.timeNames[2]:f.i18n.timeNames[3]},T:function(){return 12>_()?f.i18n.timeNames[4]:f.i18n.timeNames[5]},TT:function(){return 12>_()?f.i18n.timeNames[6]:f.i18n.timeNames[7]},Z:function(){return i?"GMT":r?"UTC":(String(e).match(u)||[""]).pop().replace(c,"").replace(/GMT\+0000/g,"UTC")},o:function(){return(O()>0?"-":"+")+h(100*Math.floor(Math.abs(O())/60)+Math.abs(O())%60,4)},p:function(){return(O()>0?"-":"+")+h(Math.floor(Math.abs(O())/60),2)+":"+h(Math.floor(Math.abs(O())%60),2)},S:function(){return["th","st","nd","rd"][m()%10>3?0:(m()%100-m()%10!=10)*m()%10]},W:function(){return j()},WW:function(){return h(j())},N:function(){return y(e)}};return t.replace(a,function(e){return e in k?k[e]():e.slice(1,e.length-1)})});f.masks={default:"ddd mmm dd yyyy HH:MM:ss",shortDate:"m/d/yy",paddedShortDate:"mm/dd/yyyy",mediumDate:"mmm d, yyyy",longDate:"mmmm d, yyyy",fullDate:"dddd, mmmm d, yyyy",shortTime:"h:MM TT",mediumTime:"h:MM:ss TT",longTime:"h:MM:ss TT Z",isoDate:"yyyy-mm-dd",isoTime:"HH:MM:ss",isoDateTime:"yyyy-mm-dd'T'HH:MM:sso",isoUtcDateTime:"UTC:yyyy-mm-dd'T'HH:MM:ss'Z'",expiresHeaderFormat:"ddd, dd mmm yyyy HH:MM:ss Z"},f.i18n={dayNames:["Sun","Mon","Tue","Wed","Thu","Fri","Sat","Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],monthNames:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec","January","February","March","April","May","June","July","August","September","October","November","December"],timeNames:["a","p","am","pm","A","P","AM","PM"]};var h=function(e,t){for(e=String(e),t=t||2;e.length<t;)e="0"+e;return e},d=function(e){var t=e.y,r=e.m,i=e.d,o=e._,s=e.dayName,a=e.short,u=void 0!==a&&a,c=new Date,l=new Date;l.setDate(l[o+"Date"]()-1);var f=new Date;return(f.setDate(f[o+"Date"]()+1),c[o+"FullYear"]()===t&&c[o+"Month"]()===r&&c[o+"Date"]()===i)?u?"Tdy":"Today":l[o+"FullYear"]()===t&&l[o+"Month"]()===r&&l[o+"Date"]()===i?u?"Ysd":"Yesterday":f[o+"FullYear"]()===t&&f[o+"Month"]()===r&&f[o+"Date"]()===i?u?"Tmw":"Tomorrow":s},p=function(e){var t=new Date(e.getFullYear(),e.getMonth(),e.getDate());t.setDate(t.getDate()-(t.getDay()+6)%7+3);var r=new Date(t.getFullYear(),0,4);r.setDate(r.getDate()-(r.getDay()+6)%7+3);var i=t.getTimezoneOffset()-r.getTimezoneOffset();return t.setHours(t.getHours()-i),1+Math.floor((t-r)/(864e5*7))},y=function(e){var t=e.getDay();return 0===t&&(t=7),t},g=function(e){return null===e?"null":void 0===e?"undefined":"object"!==o(e)?o(e):Array.isArray(e)?"array":({}).toString.call(e).slice(8,-1).toLowerCase()};void 0===(i=(function(){return f}).call(t,r,t,e))||(e.exports=i)}(void 0)},5410:(e,t,r)=>{"use strict";r(8739)},5422:(e,t,r)=>{"use strict";var i=r(1196),o=r(3531),s=r(1820),a=r(877),u=r(4563),c=r(8078),l=TypeError,f=c("toPrimitive");e.exports=function(e,t){if(!o(e)||s(e))return e;var r,c=a(e,f);if(c){if(void 0===t&&(t="default"),!o(r=i(c,e,t))||s(r))return r;throw new l("Can't convert object to primitive value")}return void 0===t&&(t="number"),u(e,t)}},5449:(e,t,r)=>{"use strict";var i=r(5773),o=r(487).add,s=r(1451),a=r(1428),u=r(8348);e.exports=function(e){var t=i(this),r=a(e).getIterator(),c=s(t);return u(r,function(e){o(c,e)}),c}},5463:e=>{"use strict";function t(e,t,r,i){function o(){let e=t.deref();void 0!==e&&r(e,i)}e[i]=o,process.once(i,o)}let r=new FinalizationRegistry(o),i=new WeakMap;function o(e){process.removeListener("exit",e.exit),process.removeListener("beforeExit",e.beforeExit)}e.exports={register:function(e,o){if(void 0===e)throw Error("the object can't be undefined");let s=new WeakRef(e),a={};i.set(e,a),r.register(e,a),t(a,s,o,"exit"),t(a,s,o,"beforeExit")},unregister:function(e){let t=i.get(e);i.delete(e),t&&o(t),r.unregister(e)}}},5486:(e,t,r)=>{var i=r(5645),o=function(){},s=function(e,t,r){if("function"==typeof t)return s(e,null,t);t||(t={}),r=i(r||o);var a=e._writableState,u=e._readableState,c=t.readable||!1!==t.readable&&e.readable,l=t.writable||!1!==t.writable&&e.writable,f=!1,h=function(){e.writable||d()},d=function(){l=!1,c||r.call(e)},p=function(){c=!1,l||r.call(e)},y=function(t){r.call(e,t?Error("exited with error code: "+t):null)},g=function(t){r.call(e,t)},m=function(){process.nextTick(b)},b=function(){if(!f&&(c&&!(u&&u.ended&&!u.destroyed)||l&&!(a&&a.ended&&!a.destroyed)))return r.call(e,Error("premature close"))},v=function(){e.req.on("finish",d)};return e.setHeader&&"function"==typeof e.abort?(e.on("complete",d),e.on("abort",m),e.req?v():e.on("request",v)):l&&!a&&(e.on("end",h),e.on("close",h)),e.stdio&&Array.isArray(e.stdio)&&3===e.stdio.length&&e.on("exit",y),e.on("end",p),e.on("finish",d),!1!==t.error&&e.on("error",g),e.on("close",m),function(){f=!0,e.removeListener("complete",d),e.removeListener("abort",m),e.removeListener("request",v),e.req&&e.req.removeListener("finish",d),e.removeListener("end",h),e.removeListener("close",h),e.removeListener("finish",d),e.removeListener("exit",y),e.removeListener("end",p),e.removeListener("error",g),e.removeListener("close",m)}};e.exports=s},5535:(e,t,r)=>{"use strict";var i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=l;var o=r(605),s=r(3581);r(3081)(l,o);for(var a=i(s.prototype),u=0;u<a.length;u++){var c=a[u];l.prototype[c]||(l.prototype[c]=s.prototype[c])}function l(e){if(!(this instanceof l))return new l(e);o.call(this,e),s.call(this,e),this.allowHalfOpen=!0,e&&(!1===e.readable&&(this.readable=!1),!1===e.writable&&(this.writable=!1),!1===e.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",f)))}function f(){this._writableState.ended||process.nextTick(h,this)}function h(e){e.end()}Object.defineProperty(l.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(l.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(l.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(l.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&this._readableState.destroyed&&this._writableState.destroyed},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}})},5550:(e,t,r)=>{"use strict";let{LEVELS:i,LEVEL_NAMES:o}=r(4249),s=e=>e,a={default:s,60:s,50:s,40:s,30:s,20:s,10:s,message:s,greyMessage:s},{createColors:u}=r(6666),c=u({useColor:!0}),{white:l,bgRed:f,red:h,yellow:d,green:p,blue:y,gray:g,cyan:m}=c,b={default:l,60:f,50:h,40:d,30:p,20:y,10:g,message:m,greyMessage:g};function v(e){return function(t,r,{customLevels:s,customLevelNames:a}={}){let u=e?s||i:Object.assign({},i,s),c=e?a||o:Object.assign({},o,a),l="default";l=Number.isInteger(+t)?Object.prototype.hasOwnProperty.call(u,t)?t:l:Object.prototype.hasOwnProperty.call(c,t.toLowerCase())?c[t.toLowerCase()]:l;let f=u[l];return Object.prototype.hasOwnProperty.call(r,l)?r[l](f):r.default(f)}}e.exports=function(e=!1,t,r){if(e&&void 0!==t){let e=t.reduce(function(e,[t,r]){return e[t]="function"==typeof c[r]?c[r]:l,e},{default:l,message:m,greyMessage:g}),i=r?e:Object.assign({},b,e),o=v(r),s=function(e,t){return o(e,i,t)};return s.message=s.message||i.message,s.greyMessage=s.greyMessage||i.greyMessage,s}if(e){let e=v(r),t=function(t,r){return e(t,b,r)};return t.message=b.message,t.greyMessage=b.greyMessage,t}let i=v(r),o=function(e,t){return i(e,a,t)};return o.message=a.message,o.greyMessage=a.greyMessage,o}},5590:(e,t,r)=>{"use strict";var i=r(697),o=r(1196),s=r(1999),a=r(2749);i({target:"Set",proto:!0,real:!0,forced:!0},{isSubsetOf:function(e){return o(a,this,s(e))}})},5629:(e,t,r)=>{"use strict";var i,o=r(8396).F,s=o.ERR_MISSING_ARGS,a=o.ERR_STREAM_DESTROYED;function u(e){if(e)throw e}function c(e){e()}function l(e,t){return e.pipe(t)}e.exports=function(){for(var e,t,o=arguments.length,f=Array(o),h=0;h<o;h++)f[h]=arguments[h];var d=(e=f).length&&"function"==typeof e[e.length-1]?e.pop():u;if(Array.isArray(f[0])&&(f=f[0]),f.length<2)throw new s("streams");var p=f.map(function(e,o){var s,u,l,h,y,g,m=o<f.length-1;return s=o>0,l=u=function(e){t||(t=e),e&&p.forEach(c),m||(p.forEach(c),d(t))},h=!1,u=function(){h||(h=!0,l.apply(void 0,arguments))},y=!1,e.on("close",function(){y=!0}),void 0===i&&(i=r(9919)),i(e,{readable:m,writable:s},function(e){if(e)return u(e);y=!0,u()}),g=!1,function(t){if(!y&&!g){if(g=!0,e.setHeader&&"function"==typeof e.abort)return e.abort();if("function"==typeof e.destroy)return e.destroy();u(t||new a("pipe"))}}});return f.reduce(l)}},5645:(e,t,r)=>{var i=r(4037);function o(e){var t=function(){return t.called?t.value:(t.called=!0,t.value=e.apply(this,arguments))};return t.called=!1,t}function s(e){var t=function(){if(t.called)throw Error(t.onceError);return t.called=!0,t.value=e.apply(this,arguments)};return t.onceError=(e.name||"Function wrapped with `once`")+" shouldn't be called more than once",t.called=!1,t}e.exports=i(o),e.exports.strict=i(s),o.proto=o(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return o(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return s(this)},configurable:!0})})},5653:(e,t,r)=>{"use strict";var i=r(8078)("toStringTag"),o={};o[i]="z",e.exports="[object z]"===String(o)},5692:e=>{"use strict";e.exports=require("https")},5698:(e,t,r)=>{"use strict";var i=r(8585),o=r(6078),s=r(4298);e.exports=!i&&!o(function(){return 7!==Object.defineProperty(s("div"),"a",{get:function(){return 7}}).a})},5773:(e,t,r)=>{"use strict";var i=r(487).has;e.exports=function(e){return i(e),e}},5805:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),r(777),r(9071);let{cacheStorage:i,CacheStorageGroup:o,getManagedCacheStorage:s}=r(4337),a=r(9588),u=r(3186),c=r(2965),l=r(23),{logScope:f}=r(6166);f("provider/bilivideo");let h=s("provider/bilivideo"),d=[46,47,18,2,53,8,23,32,15,50,10,31,58,3,45,35,27,43,5,49,33,9,42,19,29,28,14,39,12,38,41,13,37,48,7,16,24,55,40,61,26,17,0,1,60,51,30,4,22,25,54,21,56,59,6,63,57,62,11,36,20,34,44,52];async function p(){let e=await c("GET","https://api.bilibili.com/x/web-interface/nav",{"User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3",Referer:"https://www.bilibili.com/"}),{data:{wbi_img:{img_url:t,sub_url:r}}}=await e.json();return{img_key:t.slice(t.lastIndexOf("/")+1,t.lastIndexOf(".")),sub_key:r.slice(r.lastIndexOf("/")+1,r.lastIndexOf("."))}}let y=async e=>{let{img_key:t,sub_key:r}=await h.cache("wbikey",async()=>await p());return function(e,t,r){let i,o=(i=t+r,d.map(e=>i[e]).join("").slice(0,32)),s=Math.round(Date.now()/1e3),a=/[!'()*]/g;Object.assign(e,{wts:s});let u=Object.keys(e).sort().map(t=>{let r=e[t].toString().replace(a,"");return`${encodeURIComponent(t)}=${encodeURIComponent(r)}`}).join("&"),c=l.md5.digest(u+o);return u+"&w_rid="+c}(e,t,r)},g=e=>({id:e.bvid,name:e.title,artists:{id:e.typeid,name:e.typename}}),m=async()=>h.cache("bilicookie",()=>c("GET","https://www.bilibili.com").then(e=>e.headers["set-cookie"].map(e=>e.split(";")[0]).join("; "))),b=e=>y({bvid:e}).then(t=>c("GET","https://api.bilibili.com/x/web-interface/wbi/view?"+t).then(e=>e.json()).then(t=>0===t.code?y({bvid:e,cid:t.data.cid,fnval:16,platform:"pc"}).then(t=>c("GET","https://api.bilibili.com/x/player/wbi/playurl?"+t).then(e=>e.json()).then(e=>0!==e.code?Promise.reject():null!=e.data.dash.audio?e.data.dash.audio[0].base_url:Promise.reject()).catch(()=>a().bilibili.track(e))):Promise.reject()).catch(()=>a().bilibili.track(e)));e.exports={check:e=>h.cache(e,()=>(e=>m().then(t=>y({search_type:"video",keyword:e.keyword}).then(r=>c("GET","https://api.bilibili.com/x/web-interface/wbi/search/type?"+r,{cookie:t,referer:"https://search.bilibili.com"}).then(e=>e.json()).then(t=>{let r=u(t.data.result.map(g),e);return r?r.id:Promise.reject()}))))(e)).then(b),track:b}},5826:(e,t,r)=>{"use strict";var i=r(6880),o=r(3531),s=r(4690);e.exports=function(e,t,r){var a,u;return s&&i(a=t.constructor)&&a!==r&&o(u=a.prototype)&&u!==r.prototype&&s(e,u),e}},5869:(e,t,r)=>{"use strict";var i=r(6880),o=r(8498),s=TypeError;e.exports=function(e){if(i(e))return e;throw new s(o(e)+" is not a function")}},5871:(e,t,r)=>{"use strict";var i=r(8173),o=r(2870),s=r(1512),a=r(9398).indexOf,u=r(1088),c=i([].push);e.exports=function(e,t){var r,i=s(e),l=0,f=[];for(r in i)!o(u,r)&&o(i,r)&&c(f,r);for(;t.length>l;)o(i,r=t[l++])&&(~a(f,r)||c(f,r));return f}},5921:(e,t,r)=>{"use strict";var i=r(697),o=r(5869),s=r(5773),a=r(9900),u=TypeError;i({target:"Set",proto:!0,real:!0,forced:!0},{reduce:function(e){var t=s(this),r=arguments.length<2,i=r?void 0:arguments[1];if(o(e),a(t,function(o){r?(r=!1,i=o):i=e(i,o,o,t)}),r)throw new u("Reduce of empty set with no initial value");return i}})},5962:(e,t,r)=>{"use strict";var i=r(697),o=r(1196),s=r(1999),a=r(9157);i({target:"Set",proto:!0,real:!0,forced:!0},{symmetricDifference:function(e){return o(a,this,s(e))}})},5966:(e,t,r)=>{"use strict";let{groupRestore:i,nestedRestore:o}=r(1022);e.exports=function(){return function(){var e;if(this.restore){this.restore.state.secret=this.secret;return}let{secret:t,wcLen:r}=this,s=Object.keys(t),a=(e=t,s.map(t=>{let{circle:r,escPath:i,leadingBracket:o}=e[t],s=r?`o.${r} = secret[${i}].val`:`o${o?"":"."}${t} = secret[${i}].val`,a=`secret[${i}].val = undefined`;return`
10 if (secret[${i}].val !== undefined) {
11 try { ${s} } catch (e) {}
12 ${a}

Callers 1

JFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected