diff options
| author | Factiven <[email protected]> | 2023-04-17 14:04:08 +0700 |
|---|---|---|
| committer | Factiven <[email protected]> | 2023-04-17 14:04:08 +0700 |
| commit | cf587f75c593dd234d33a77a0044aea2429c4b98 (patch) | |
| tree | b6b8fa14cb365cab8a288981d08405546dc9b389 | |
| parent | Delete testing.js (diff) | |
| download | moopa-cf587f75c593dd234d33a77a0044aea2429c4b98.tar.xz moopa-cf587f75c593dd234d33a77a0044aea2429c4b98.zip | |
2nd fixes
| -rw-r--r-- | pages/anime/[...id].js | 2 | ||||
| -rw-r--r-- | pages/anime/watch/[...info].js | 2 | ||||
| -rw-r--r-- | pages/api/get-media.js | 2 | ||||
| -rw-r--r-- | pages/profile/[user].js | 2 |
4 files changed, 3 insertions, 5 deletions
diff --git a/pages/anime/[...id].js b/pages/anime/[...id].js index 4e0d1d1..91a3eed 100644 --- a/pages/anime/[...id].js +++ b/pages/anime/[...id].js @@ -615,7 +615,7 @@ export async function getServerSideProps(context) { let lastPlayed = null; if (session) { - const res = await fetch(`/api/get-media`, { + const res = await fetch(`https://moopa-anilist.vercel.app/api/get-media`, { method: "POST", body: JSON.stringify({ username: session?.user.name, diff --git a/pages/anime/watch/[...info].js b/pages/anime/watch/[...info].js index 33e30a2..4d4d420 100644 --- a/pages/anime/watch/[...info].js +++ b/pages/anime/watch/[...info].js @@ -423,7 +423,7 @@ export async function getServerSideProps(context) { .filter((item) => item.id == id) .map((item) => item.number); - const resp = await fetch(`/api/get-media`, { + const resp = await fetch(`https://moopa-anilist.vercel.app/api/get-media`, { method: "POST", body: JSON.stringify({ username: session?.user.name, diff --git a/pages/api/get-media.js b/pages/api/get-media.js index 7c45d03..4c65654 100644 --- a/pages/api/get-media.js +++ b/pages/api/get-media.js @@ -1,5 +1,3 @@ -// pages/api/anime-media-list.js - export default async function handler(req, res) { const { username, status } = req.body; diff --git a/pages/profile/[user].js b/pages/profile/[user].js index 3cff4bd..f53a494 100644 --- a/pages/profile/[user].js +++ b/pages/profile/[user].js @@ -299,7 +299,7 @@ export async function getServerSideProps(context) { const session = await getServerSession(context.req, context.res, authOptions); const query = context.query; - const res = await fetch(`/api/get-media`, { + const res = await fetch(`https://moopa-anilist.vercel.app/api/get-media`, { method: "POST", body: JSON.stringify({ username: query.user, |