更新 'SrcJyAlist.js'

master
src48597962 2 years ago
parent 2af6ea8811
commit fcd24a9de5
  1. 5
      SrcJyAlist.js

@ -474,7 +474,7 @@ function alistSearch(alistapi,input) {
let txt = pdfh(item,"a&&href"); let txt = pdfh(item,"a&&href");
let parent = txt.substring(0,txt.lastIndexOf("/")); let parent = txt.substring(0,txt.lastIndexOf("/"));
let name = txt.substring(txt.lastIndexOf('/')+1); let name = txt.substring(txt.lastIndexOf('/')+1);
let suffix = name.substring(txt.lastIndexOf('.')+1); let suffix = name.substring(name.lastIndexOf('.')+1);
if(suffix.length>3 && !contain.test(suffix) && !dirlist.some(d => d.parent+'/'+d.name==parent)){ if(suffix.length>3 && !contain.test(suffix) && !dirlist.some(d => d.parent+'/'+d.name==parent)){
dirlist.push({ dirlist.push({
"parent": parent, "parent": parent,
@ -482,13 +482,14 @@ function alistSearch(alistapi,input) {
"is_dir": true "is_dir": true
}) })
}else if(contain.test(suffix) && !dirlist.some(d => d.parent+'/'+d.name==parent)){ }else if(contain.test(suffix) && !dirlist.some(d => d.parent+'/'+d.name==parent)){
filelist.push({ filelist.push({
"parent": parent, "parent": parent,
"name": name, "name": name,
"is_dir": false "is_dir": false
}) })
}else{ }else{
log(name); log(name);
log(suffix);
} }
}) })
}catch(e){ }catch(e){

Loading…
Cancel
Save