Merge pull request '콘텐츠 댓글 푸시 대상자' (#246) from test into main

Reviewed-on: #246
This commit is contained in:
klaus 2024-12-03 15:54:34 +00:00
commit e334d1e5d9
1 changed files with 3 additions and 4 deletions

View File

@ -191,13 +191,13 @@ class AudioContentCommentQueryRepositoryImpl(
): List<FindPushTokenByContentIdAndCommentParentIdMyMemberIdResponse> {
var where = audioContent.id.eq(contentId)
.and(member.id.ne(myMemberId))
.and(audioContentComment.isActive.isTrue)
if (commentParentId != null) {
where = where.and(
audioContentComment.parent.id.eq(commentParentId)
.or(audioContentComment.id.eq(commentParentId))
)
.and(audioContentComment.isActive.isTrue)
}
val response = if (commentParentId != null) {
@ -221,9 +221,8 @@ class AudioContentCommentQueryRepositoryImpl(
member.container
)
)
.from(audioContentComment)
.innerJoin(audioContentComment.audioContent, audioContent)
.innerJoin(audioContentComment.member, member)
.from(audioContent)
.innerJoin(audioContent.member, member)
.where(where)
.fetch()
}