Skip to content
Snippets Groups Projects
Unverified Commit 2de4d332 authored by おさむのひと's avatar おさむのひと Committed by GitHub
Browse files

Fix: フォローしたユーザが、自分のフォローしていないチャンネルにノートを投稿した時、そのノートがHTLで見えてしまう (#12186)


* #12181 の問題に対処
「ユーザー・チャンネルともにフォローあり」のときの絞り込みに不備があり、フォローしているユーザの投稿であればチャンネルのフォロー関係なく通過するようになってしまっていた

* fix CHANGELOG.md

---------

Co-authored-by: default avatarosamu <46447427+sam-osamu@users.noreply.github.com>
parent 8f01757a
No related branches found
No related tags found
No related merge requests found
......@@ -49,7 +49,7 @@
- Fix: RedisへのTLキャッシュが有効の場合にHTL/LTL/STLが空になることがある問題を修正
- Fix: STLでフォローしていないチャンネルが取得される問題を修正
- Fix: `hashtags/trend`にてRedisからトレンドの情報が取得できない際にInternal Server Errorになる問題を修正
- Fix: HTLをリロードまたは遡行したとき、フォローしているチャンネルのノートが含まれない問題を修正 #11765
- Fix: HTLをリロードまたは遡行したとき、フォローしているチャンネルのノートが含まれない問題を修正 #11765 #12181
## 2023.10.2
......
......@@ -183,7 +183,11 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
const followingChannelIds = followingChannels.map(x => x.followeeId);
query.andWhere(new Brackets(qb => {
qb
.where('note.userId IN (:...meOrFolloweeIds)', { meOrFolloweeIds: meOrFolloweeIds })
.where(new Brackets(qb2 => {
qb2
.where('note.userId IN (:...meOrFolloweeIds)', { meOrFolloweeIds: meOrFolloweeIds })
.andWhere('note.channelId IS NULL');
}))
.orWhere('note.channelId IN (:...followingChannelIds)', { followingChannelIds });
}));
} else if (followees.length > 0) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment