mirror of
https://github.com/vega-org/vega-providers.git
synced 2026-04-17 23:51:44 +00:00
build
This commit is contained in:
2
dist/netflixMirror/meta.js
vendored
2
dist/netflixMirror/meta.js
vendored
@@ -1 +1 @@
|
||||
var __awaiter=this&&this.__awaiter||function(thisArg,_arguments,P,generator){return new(P||(P=Promise))(function(resolve,reject){function fulfilled(value){try{step(generator.next(value))}catch(e){reject(e)}}function rejected(value){try{step(generator.throw(value))}catch(e){reject(e)}}function step(result){var value;result.done?resolve(result.value):(value=result.value,value instanceof P?value:new P(function(resolve){resolve(value)})).then(fulfilled,rejected)}step((generator=generator.apply(thisArg,_arguments||[])).next())})};exports.getMeta=void 0;const getMeta=function(_a){return __awaiter(this,arguments,void 0,function*({link:link}){var _b,_c,_d,_e;try{const url=`https://netmirror.8man.dev/api/net-proxy?${"isPrime=false"}&url=${encodeURIComponent(link)}`,res=yield fetch(url,{credentials:"omit"}),data=yield res.json(),id=null===(_b=link.split("id=")[1])||void 0===_b?void 0:_b.split("&")[0],meta={title:data.title,synopsis:data.desc,image:`https://img.nfmirrorcdn.top/poster/h/${id}.jpg`,cast:null===(_c=null==data?void 0:data.short_cast)||void 0===_c?void 0:_c.split(","),tags:[null==data?void 0:data.year,null==data?void 0:data.hdsd,...null===(_d=null==data?void 0:data.thismovieis)||void 0===_d?void 0:_d.split(",")],imdbId:"",type:"series"},linkList=[];return(null===(_e=null==data?void 0:data.season)||void 0===_e?void 0:_e.length)>0?data.season.map(season=>{linkList.push({title:"Season "+(null==season?void 0:season.s),episodesLink:null==season?void 0:season.id})}):linkList.push({title:meta.title,directLinks:[{link:id,title:"Movie",type:"movie"}]}),Object.assign(Object.assign({},meta),{linkList:linkList})}catch(err){return{title:"",synopsis:"",image:"",imdbId:"",type:"",linkList:[]}}})};exports.getMeta=getMeta;
|
||||
"use strict";var __defProp=Object.defineProperty,__defProps=Object.defineProperties,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropDescs=Object.getOwnPropertyDescriptors,__getOwnPropNames=Object.getOwnPropertyNames,__getOwnPropSymbols=Object.getOwnPropertySymbols,__hasOwnProp=Object.prototype.hasOwnProperty,__propIsEnum=Object.prototype.propertyIsEnumerable,__defNormalProp=(e,t,r)=>t in e?__defProp(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,__spreadValues=(e,t)=>{for(var r in t||(t={}))__hasOwnProp.call(t,r)&&__defNormalProp(e,r,t[r]);if(__getOwnPropSymbols)for(var r of __getOwnPropSymbols(t))__propIsEnum.call(t,r)&&__defNormalProp(e,r,t[r]);return e},__spreadProps=(e,t)=>__defProps(e,__getOwnPropDescs(t)),__name=(e,t)=>__defProp(e,"name",{value:t,configurable:!0}),__export=(e,t)=>{for(var r in t)__defProp(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,r,o)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let s of __getOwnPropNames(t))__hasOwnProp.call(e,s)||s===r||__defProp(e,s,{get:()=>t[s],enumerable:!(o=__getOwnPropDesc(t,s))||o.enumerable});return e},__toCommonJS=e=>__copyProps(__defProp({},"__esModule",{value:!0}),e),__async=(e,t,r)=>new Promise((o,s)=>{var n=e=>{try{_(r.next(e))}catch(e){s(e)}},p=e=>{try{_(r.throw(e))}catch(e){s(e)}},_=e=>e.done?o(e.value):Promise.resolve(e.value).then(n,p);_((r=r.apply(e,t)).next())}),meta_exports={};__export(meta_exports,{getMeta:()=>getMeta});var getMeta=__name(function(e){return __async(this,arguments,function*({link:e}){var t,r,o,s;try{const n=`https://netmirror.8man.dev/api/net-proxy?isPrime=false&url=${encodeURIComponent(e)}`,p=yield fetch(n,{credentials:"omit"}),_=yield p.json(),i=null==(t=e.split("id=")[1])?void 0:t.split("&")[0],l={title:_.title,synopsis:_.desc,image:`https://img.nfmirrorcdn.top/poster/h/${i}.jpg`,cast:null==(r=null==_?void 0:_.short_cast)?void 0:r.split(","),tags:[null==_?void 0:_.year,null==_?void 0:_.hdsd,...null==(o=null==_?void 0:_.thismovieis)?void 0:o.split(",")],imdbId:"",type:"series"},a=[];return(null==(s=null==_?void 0:_.season)?void 0:s.length)>0?_.season.map(e=>{a.push({title:"Season "+(null==e?void 0:e.s),episodesLink:null==e?void 0:e.id})}):a.push({title:l.title,directLinks:[{link:i,title:"Movie",type:"movie"}]}),__spreadProps(__spreadValues({},l),{linkList:a})}catch(e){return{title:"",synopsis:"",image:"",imdbId:"",type:"",linkList:[]}}})},"getMeta");exports.getMeta=getMeta;
|
||||
Reference in New Issue
Block a user