Skip to content

Commit

Permalink
hotfix: 단체 관리자가 작성한 게시글에서 관계 점수 고려 하지 않기
Browse files Browse the repository at this point in the history
관리자와의 관계 점수는 없으므로 조건에 추가했습니다.
  • Loading branch information
HABINOH committed May 13, 2024
1 parent 7a578c3 commit 95291f7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ public Long write(CommentRequest request) {
.orElseThrow(() -> new GlobalException(ErrorCode.MEMBER_NOT_IN_ORGANIZATION));
}

if (post.getAuthor().getId() != commentWriter.getId()) {
if (post.getAuthor().getId() != commentWriter.getId() &&
post.getAuthor().getRole() == Role.STUDENT) {
//해당 게시글에 반응(댓글 작성)을 하였는지 확인
boolean isFirstComment = request.parentId() == 0L
&& !commentRepository.existsByPostAndMember(post, commentWriter);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,11 @@ public void singleFcmSend(Member member, FcmDTO fcmDTO) {
}

public void multiFcmSend(List<Member> members, FcmDTO fcmDTO) {
members.forEach(member -> singleFcmSend(member, fcmDTO));
members.forEach(member ->
Thread.startVirtualThread(() ->
singleFcmSend(member, fcmDTO)
)
);
}

private String getFcmRedisKey(Long memberId) {
Expand Down

0 comments on commit 95291f7

Please sign in to comment.