blob: 602427ba40e4f176991ee2736147c8164212e66e (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
export const GET = async ({ url }) => {
try {
return Response.json(
await (
await fetch(
`https://api.mangadex.org/chapter?manga=${url.searchParams.get(
'id'
)}&chapter=${url.searchParams.get(
'chapter'
)}&contentRating[]=safe&contentRating[]=suggestive&contentRating[]=erotica&contentRating[]=pornographic&limit=1`
)
).json()
);
} catch {
return new Response('rate-limited');
}
};
|