1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-01 22:06:02 +02:00

fix(backend): notes/mentions で場合によっては並び順が正しく返されない問題を修正

Fix #16398
This commit is contained in:
syuilo
2025-08-21 19:10:16 +09:00
parent 1eabb21d69
commit 8cbbb80e3f
2 changed files with 2 additions and 1 deletions

View File

@@ -66,7 +66,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
.orWhere(':meIdAsList <@ note.visibleUserIds');
}))
// Avoid scanning primary key index
.orderBy('CONCAT(note.id)', 'DESC')
.orderBy('CONCAT(note.id)', (ps.sinceDate || ps.sinceId) ? 'ASC' : 'DESC')
.innerJoinAndSelect('note.user', 'user')
.leftJoinAndSelect('note.reply', 'reply')
.leftJoinAndSelect('note.renote', 'renote')