From 97d128aa5c197c90f4062f5296908a9ba7566759 Mon Sep 17 00:00:00 2001 From: Namekuji Date: Mon, 18 Sep 2023 22:19:58 -0400 Subject: [PATCH] fix: order by --- packages/backend/src/server/api/endpoints/clips/notes.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/backend/src/server/api/endpoints/clips/notes.ts b/packages/backend/src/server/api/endpoints/clips/notes.ts index ff5330b9f7..1e8043fe18 100644 --- a/packages/backend/src/server/api/endpoints/clips/notes.ts +++ b/packages/backend/src/server/api/endpoints/clips/notes.ts @@ -91,7 +91,7 @@ export default define(meta, paramDef, async (ps, user) => { const noteIds = await ClipNotes.find({ where: whereOpt, - order: { id: "DESC" }, + order: { noteId: "DESC" }, take: ps.limit * 5, }).then((clips) => clips.map(({ noteId }) => noteId));