Skip to content

Commit

Permalink
Merge pull request #28 from cgyrock/main-1
Browse files Browse the repository at this point in the history
fix 更新反代脚本,解决文件列表接口有时相应400的问题
  • Loading branch information
tjsky authored Sep 2, 2023
2 parents 26ec8c2 + 4c46a14 commit ddddbdc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cf-worker/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ addEventListener('fetch', event => {
}
}
// 发起 fetch
let fr = (await fetch(url, fp));
let fr = (await fetch(new URL(url), fp));
outCt = fr.headers.get('content-type');
if(outCt && (outCt.includes('application/text') || outCt.includes('text/html'))) {
try {
Expand Down Expand Up @@ -132,4 +132,4 @@ addEventListener('fetch', event => {
let len = blocker.keys.filter(x => url.includes(x)).length;
return len != 0;
}
}
}

0 comments on commit ddddbdc

Please sign in to comment.