fix: order by

This commit is contained in:
Namekuji 2023-09-18 22:19:58 -04:00
parent e25d0603d6
commit 97d128aa5c
No known key found for this signature in database
GPG key ID: 1D62332C07FBA532

View file

@ -91,7 +91,7 @@ export default define(meta, paramDef, async (ps, user) => {
const noteIds = await ClipNotes.find({ const noteIds = await ClipNotes.find({
where: whereOpt, where: whereOpt,
order: { id: "DESC" }, order: { noteId: "DESC" },
take: ps.limit * 5, take: ps.limit * 5,
}).then((clips) => clips.map(({ noteId }) => noteId)); }).then((clips) => clips.map(({ noteId }) => noteId));