From 17004f47c7c1b64949031f16ca2e814bc8919df3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?alikia2x=20=28=E5=AF=92=E5=AF=92=29?= Date: Tue, 2 Dec 2025 10:18:31 +0800 Subject: [PATCH] fix: unexpected hard-coding user ID --- packages/backend/routes/video/label.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/backend/routes/video/label.ts b/packages/backend/routes/video/label.ts index 64965f4..2a27f5b 100644 --- a/packages/backend/routes/video/label.ts +++ b/packages/backend/routes/video/label.ts @@ -21,7 +21,7 @@ const videoSchema = BiliVideoSchema.omit({ publishedAt: true }) export const getUnlabelledVideos = new Elysia({ prefix: "/videos" }).use(requireAuth).get( "/unlabelled", - async () => { + async ({ user }) => { return db.execute>(sql` SELECT bm.*, ls.views, bu.username, bu.uid FROM ( @@ -43,8 +43,8 @@ export const getUnlabelledVideos = new Elysia({ prefix: "/videos" }).use(require WHERE aid IN ( SELECT aid FROM internal.video_type_label - TABLESAMPLE SYSTEM (2) - WHERE user != 'i3wW8JdZ9sT3ASkk' + TABLESAMPLE SYSTEM (10) + WHERE user != ${user!.unqId} ORDER BY RANDOM() LIMIT 20 )