Skip to content

Commit

Permalink
Refactor request headers in _worker.js
Browse files Browse the repository at this point in the history
  • Loading branch information
3Kmfi6HP committed Mar 23, 2024
1 parent 54a43d7 commit 67b3c2e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions _worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,9 @@ export default {
});
};
case `/bestip/${userID_Path}`: {
const userAgent = request.headers.get('User-Agent');
const headers = request.headers;
const url = `https://sub.xf.free.hr/auto?host=${request.headers.get('Host')}&uuid=${userID}&path=/`;
const bestSubConfig = await fetch(url, { headers: { 'User-Agent': userAgent } });
const bestSubConfig = await fetch(url, { headers: headers });
return bestSubConfig;
};
default:
Expand Down

0 comments on commit 67b3c2e

Please sign in to comment.