mirror of
https://github.com/vega-org/vega-providers.git
synced 2026-04-17 23:51:44 +00:00
1 line
1.2 KiB
JavaScript
1 line
1.2 KiB
JavaScript
"use strict";var __defProp=Object.defineProperty,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropNames=Object.getOwnPropertyNames,__hasOwnProp=Object.prototype.hasOwnProperty,__name=(e,r)=>__defProp(e,"name",{value:r,configurable:!0}),__export=(e,r)=>{for(var t in r)__defProp(e,t,{get:r[t],enumerable:!0})},__copyProps=(e,r,t,o)=>{if(r&&"object"==typeof r||"function"==typeof r)for(let n of __getOwnPropNames(r))__hasOwnProp.call(e,n)||n===t||__defProp(e,n,{get:()=>r[n],enumerable:!(o=__getOwnPropDesc(r,n))||o.enumerable});return e},__toCommonJS=e=>__copyProps(__defProp({},"__esModule",{value:!0}),e),__async=(e,r,t)=>new Promise((o,n)=>{var _=e=>{try{p(t.next(e))}catch(e){n(e)}},a=e=>{try{p(t.throw(e))}catch(e){n(e)}},p=e=>e.done?o(e.value):Promise.resolve(e.value).then(_,a);p((t=t.apply(e,r)).next())}),stream_exports={};__export(stream_exports,{getStream:()=>getStream});var getStream=__name(function(e){return __async(this,arguments,function*({link:e,type:r,providerContext:t}){const{axios:o,cheerio:n}=t;try{const r=[],t=JSON.parse(e);return r.push({link:t.url,server:t.title||"Unknown Server",type:"mp4"}),r}catch(e){return[]}})},"getStream");exports.getStream=getStream; |