From cd19f39005b34174a549a246e303e7481aa46e15 Mon Sep 17 00:00:00 2001 From: Rushil Perera Date: Fri, 19 Dec 2025 00:27:38 -0500 Subject: [PATCH] fix: titles sync not working --- src/controllers/auth/anilist/index.ts | 14 +++++--------- src/index.ts | 2 -- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/src/controllers/auth/anilist/index.ts b/src/controllers/auth/anilist/index.ts index bbdadfb..c8f0ec6 100644 --- a/src/controllers/auth/anilist/index.ts +++ b/src/controllers/auth/anilist/index.ts @@ -129,15 +129,11 @@ app.openapi(route, async (c) => { let hasNextPage = true; do { - const stub = env.ANILIST_DO.getByName(user.name!); - const { mediaList, pageInfo } = await stub - .getTitles( - user.name!, - currentPage++, - ["CURRENT", "PLANNING", "PAUSED", "REPEATING"], - aniListToken, - ) - .then((data) => data!); + const { mediaList, pageInfo } = await getWatchingTitles( + user.name!, + currentPage++, + aniListToken, + ).then((data) => data!); if (!mediaList) { break; } diff --git a/src/index.ts b/src/index.ts index 19d54b2..c2e4913 100644 --- a/src/index.ts +++ b/src/index.ts @@ -12,8 +12,6 @@ import { } from "~/libs/tasks/queueTask"; import { maybeUpdateLastConnectedAt } from "~/middleware/maybeUpdateLastConnectedAt"; -import { checkUpcomingTitles } from "./controllers/internal/upcoming-titles"; - export const app = new OpenAPIHono<{ Bindings: Env }>(); app.use(maybeUpdateLastConnectedAt);