Skip to content

Commit 0367a0f

Browse files
committed
fix
1 parent d6faadf commit 0367a0f

1 file changed

Lines changed: 8 additions & 21 deletions

File tree

HacgGodTurn.user.js

Lines changed: 8 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
// @include http*://acgmoon.*
4747
// @include http*://www.moe-acg.cc/*
4848
// @include http*://htai.*
49-
// @version 3.20.31
49+
// @version 3.20.32
5050
// @grant GM_notification
5151
// @grant GM_xmlhttpRequest
5252
// @run-at document-end
@@ -236,6 +236,7 @@
236236
}
237237
};
238238
}
239+
239240
var t, curSite, curArticle;
240241
var contentArea='.entry-content', commArea="comment-content";
241242
var originTitile = document.title;
@@ -329,10 +330,6 @@
329330
articleSel="section.card";
330331
if(isHttps)
331332
addInsertHandler([["a","img","link","script"],[['p:(\\\/\\\/|\\\\\\/\\\\\\/)(www\\\.|static\\\.)?acg12','ps:$1$2acg12']]]);
332-
curSite.getDownPass=function(target){
333-
var pass2=target.parentNode.parentNode.parentNode.querySelector('input.form-control');
334-
if(pass2)target.href+='#'+pass2.value;
335-
};
336333
break;
337334
case "sijihuisuo":
338335
if(curSite.innerPage.test(location.href)){
@@ -394,17 +391,9 @@
394391
break;
395392
case "lifan":
396393
articleSel="section.card";
397-
curSite.getDownPass=function(target){
398-
var pass2=target.parentNode.parentNode.parentNode.querySelector('input.form-control');
399-
if(pass2)target.href+='#'+pass2.value;
400-
};
401394
break;
402395
case "moe-acg":
403396
articleSel="section.card";
404-
curSite.getDownPass=function(target){
405-
var pass2=target.parentNode.parentNode.parentNode.querySelector('input.form-control');
406-
if(pass2)target.href+='#'+pass2.value;
407-
};
408397
break;
409398
case "acggj":
410399
articleSel="section.card";
@@ -423,10 +412,6 @@
423412
case "acgnz":
424413
articleSel="section.card";
425414
if(isHttps)addInsertHandler([["a","img","link","script"],[['p:(\\\/\\\/|\\\\\\/\\\\\\/)(www\\\.)?acgnz','ps:$1$2acgnz']]]);
426-
curSite.getDownPass=function(target){
427-
var pass2=target.parentNode.parentNode.parentNode.querySelector('input.form-control');
428-
if(pass2)target.href+='#'+pass2.value;
429-
};
430415
break;
431416
case "nacg":
432417
contentArea='.content';
@@ -541,10 +526,6 @@
541526
break;
542527
case "mhecy":
543528
articleSel="section.card";
544-
curSite.getDownPass=function(target){
545-
var pass=target.parentNode.parentNode.parentNode.querySelector('input.form-control');
546-
if(pass&&pass.id.indexOf("downloadPwd")!=-1)target.href=target.href.split("#")[0]+'#'+pass.value;
547-
};
548529
break;
549530
case "acg18":
550531
changeUrl(true,[["a"],[['https?:\\\/\\\/[^\\\.]*(\\\.)?acg18\\\.us\\\/go\\\/\\\?url=','']]]);
@@ -556,6 +537,12 @@
556537
}
557538
}
558539
if(curSite && curSite.downloadUrl && curSite.downloadUrl.test(location.href)){
540+
if(!curSite.getDownPass){
541+
curSite.getDownPass=function(target){
542+
var pass=target.parentNode.parentNode.parentNode.querySelector('input.form-control');
543+
if(pass)target.href=target.href.split("#")[0]+'#'+pass.value;
544+
};
545+
}
559546
t=window.setInterval(function(){
560547
if(document.querySelector('.btn-success')){
561548
clearInterval(t);

0 commit comments

Comments
 (0)