update SrcParseS.js.

pull/1/head
src48597962 3 years ago committed by Gitee
parent bb2d8d7750
commit 4cbca858a2
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
  1. 17
      SrcParseS.js

@ -473,7 +473,6 @@ var SrcParseS = {
} }
}, },
聚影: function (vipUrl,parseStr) { 聚影: function (vipUrl,parseStr) {
log(parseStr)
//聚影采用新的、独立的解析逻辑 //聚影采用新的、独立的解析逻辑
var cfgfile = "hiker://files/rules/Src/Juying/config.json"; var cfgfile = "hiker://files/rules/Src/Juying/config.json";
var Juyingcfg=fetch(cfgfile); var Juyingcfg=fetch(cfgfile);
@ -553,13 +552,10 @@ var SrcParseS = {
} }
var excludeurl = recordlist.excludeurl||[]; var excludeurl = recordlist.excludeurl||[];
var excludeparse = recordlist.excludeparse||[]; var excludeparse = recordlist.excludeparse||[];
try { var recordparse = recordlist.parse[from];
var recordparse = recordlist.parse[from]; var recordname = recordlist.name[from]||"***";
var recordname = recordlist.name[from]||"***"; var recordhead = recordlist.head[from]||{};
} catch (e) {
var recordparse = "";
var recordname = "***";
}
if(parseStr){ if(parseStr){
//指定解析用于测试 //指定解析用于测试
@ -753,7 +749,7 @@ var SrcParseS = {
if(recordparse&&forcedn==0&&mulnum<=1&&!parseStr){ if(recordparse&&forcedn==0&&mulnum<=1&&!parseStr){
//优先上次成功的 //优先上次成功的
playurl = task({ulist:{parse:recordparse, name:recordname}, vipUrl:vipUrl}).url; playurl = task({ulist:{parse:recordparse, name:recordname, header:recordhead}, vipUrl:vipUrl}).url;
if(contain.test(playurl)&&!exclude.test(playurl)&&excludeurl.indexOf(playurl)==-1){ if(contain.test(playurl)&&!exclude.test(playurl)&&excludeurl.indexOf(playurl)==-1){
if(printlog==1){log("优先上次解析("+recordname+")成功>"+playurl)}; if(printlog==1){log("优先上次解析("+recordname+")成功>"+playurl)};
@ -886,9 +882,10 @@ var SrcParseS = {
if(printlog==1){log(beparses[k].name+',记录为片源'+from+'的优先')}; if(printlog==1){log(beparses[k].name+',记录为片源'+from+'的优先')};
recordlist['parse'] = recordlist['parse']||{}; recordlist['parse'] = recordlist['parse']||{};
recordlist['parse'][from] = parseurl; recordlist['parse'][from] = parseurl;
recordlist['name'] = recordlist['name']||{}; recordlist['name'] = recordlist['name']||{};
recordlist['name'][from] = beparses[k].name; recordlist['name'][from] = beparses[k].name;
recordlist['head'] = recordlist['head']||{};
recordlist['head'][from] = beparses[k].header;
recordlist['from']= recordlist['from']||[]; recordlist['from']= recordlist['from']||[];
if(recordlist['from'].indexOf(from)==-1){recordlist['from'].push(from)} if(recordlist['from'].indexOf(from)==-1){recordlist['from'].push(from)}
writeFile(recordfile, JSON.stringify(recordlist)); writeFile(recordfile, JSON.stringify(recordlist));

Loading…
Cancel
Save