Merged
Conversation
sinsehwan
reviewed
Apr 8, 2026
Collaborator
sinsehwan
left a comment
There was a problem hiding this comment.
고생하셨습니다! 궁금한 거 몇 개 남겼어요
| .join(diaryLikeEntity.user, userEntity).fetchJoin() | ||
| .where( | ||
| diaryLikeEntity.diary.id.eq(diaryId), | ||
| diaryLikeEntity.user.id.notIn(blockedUserIds), |
Collaborator
There was a problem hiding this comment.
빈 set이 넘어갈 때 null로 분기처리하면 더 안전할 것 같습니다
Collaborator
Author
There was a problem hiding this comment.
넵 BooleanExpression으로 따로 빼겠습니다!
|
|
||
| Set<Long> blockedUserIds = userBlockLowService.getBlockedUserIds(userId); | ||
|
|
||
| blockedUserIds.add(userId); // 랜덤에서는 본인 아이디도 제외 |
Collaborator
There was a problem hiding this comment.
응답 set을 변경하기보다 새로 만들어서 조합하는 것이 더 직관적일 것 같습니다!
Set<Long> blockedUserIds = new HashSet<>(userBlockLowService.getBlockedUserIds(userId));
blockedUserIds.add(userId);| private final UserLowService userLowService; | ||
| private final SubscribeLowService subscribeLowService; | ||
|
|
||
| public void addBlockedUser(Long blockedUserId, Long blockerId) { |
Collaborator
There was a problem hiding this comment.
만약 blockedUserId랑 blockerId가 같으면 어떻게 되나요?
Collaborator
Author
There was a problem hiding this comment.
오... BadRequest로 막도록하겠습니다!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
변경점 👍
close: #46
유저 차단 기능 구현 완료했습니다.
차단했거나 차단된 유저는 다음과 같은 정책을 따릅니다.