From cd8fda50c81defd8e6700dbb38c1281e914fb34b Mon Sep 17 00:00:00 2001 From: syuilo Date: Sun, 8 Oct 2023 08:25:37 +0900 Subject: [PATCH] fix(backend): fix of 8c684d5391 --- packages/backend/src/server/api/endpoints/users/notes.ts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/packages/backend/src/server/api/endpoints/users/notes.ts b/packages/backend/src/server/api/endpoints/users/notes.ts index cd05703737..71aa6e661c 100644 --- a/packages/backend/src/server/api/endpoints/users/notes.ts +++ b/packages/backend/src/server/api/endpoints/users/notes.ts @@ -157,10 +157,9 @@ export default class extends Endpoint { // eslint- .leftJoinAndSelect('reply.user', 'replyUser') .leftJoinAndSelect('renote.user', 'renoteUser'); - query.andWhere(new Brackets(qb => { - qb.orWhere('note.channelId IS NULL'); - qb.orWhere('channel.isSensitive = false'); - })); + if (!ps.withChannelNotes) { + query.andWhere('note.channelId IS NULL'); + } this.queryService.generateVisibilityQuery(query, me);