This repository has been archived by the owner on Jan 4, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
resolvido problema de acessar episódios por conta do IP no Cloudflare.
- Loading branch information
1 parent
3e97326
commit fb0dc5a
Showing
8 changed files
with
79 additions
and
12 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
export async function GET(request) { | ||
const query = request.nextUrl.searchParams.get("q"); | ||
|
||
if (!query) | ||
return Response.json({ error: "missing query." }, { status: 401 }); | ||
|
||
const res = await fetch(query, { | ||
headers: { | ||
"Origin": "https://www.anroll.net", | ||
"Referer": "https://www.anroll.net/", | ||
"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36" | ||
}, | ||
cache: "no-store" | ||
}); | ||
|
||
const imageBuffer = await res.arrayBuffer(); | ||
const contentLength = imageBuffer.byteLength; | ||
|
||
return new Response(imageBuffer, { | ||
status: 200, | ||
headers: { | ||
"Content-Type": "image/webp", | ||
"Content-Disposition": "inline", | ||
"Content-Length": contentLength | ||
}, | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
const config = { | ||
anroll: { | ||
buildId: "nxb43Ok4qvT2cAlD0OLS1", | ||
cdn: "cdn-zenitsu-2-gamabunta.b-cdn.net" | ||
} | ||
} | ||
|
||
export default config; |