chore: STLのdb fallbackでwithRepliesがtrueのときにすべてのリプライを除外しないように (#12075)

MiFollowingを見るのは実装コストが高いため現状実装していない

Co-authored-by: syuilo <Syuilotan@yahoo.co.jp>
This commit is contained in:
anatawa12 2023-10-19 19:34:52 +09:00 committed by GitHub
parent 9afcdd10ed
commit 991fa054a6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 11 additions and 9 deletions

View File

@ -182,6 +182,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
.leftJoinAndSelect('reply.user', 'replyUser') .leftJoinAndSelect('reply.user', 'replyUser')
.leftJoinAndSelect('renote.user', 'renoteUser'); .leftJoinAndSelect('renote.user', 'renoteUser');
if (!ps.withReplies) {
query.andWhere(new Brackets(qb => { query.andWhere(new Brackets(qb => {
qb qb
.where('note.replyId IS NULL') // 返信ではない .where('note.replyId IS NULL') // 返信ではない
@ -191,6 +192,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
.andWhere('note.replyUserId = note.userId'); .andWhere('note.replyUserId = note.userId');
})); }));
})); }));
}
this.queryService.generateVisibilityQuery(query, me); this.queryService.generateVisibilityQuery(query, me);
this.queryService.generateMutedUserQuery(query, me); this.queryService.generateMutedUserQuery(query, me);