From 27f4d78f0d023fe14815afdc7bb617b610b1b480 Mon Sep 17 00:00:00 2001 From: Klaus Date: Tue, 5 Sep 2023 11:12:02 +0900 Subject: [PATCH] =?UTF-8?q?=EC=BD=98=ED=85=90=EC=B8=A0=20=EB=8C=93?= =?UTF-8?q?=EA=B8=80=20-=20=EB=8C=93=EA=B8=80=20=EC=88=98=EC=A0=95=20?= =?UTF-8?q?=EB=A1=9C=EC=A7=81=20=EB=A6=AC=ED=8C=A9=ED=86=A0=EB=A7=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../comment/AudioContentCommentService.kt | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/src/main/kotlin/kr/co/vividnext/sodalive/content/comment/AudioContentCommentService.kt b/src/main/kotlin/kr/co/vividnext/sodalive/content/comment/AudioContentCommentService.kt index fb6f527..69a6ad4 100644 --- a/src/main/kotlin/kr/co/vividnext/sodalive/content/comment/AudioContentCommentService.kt +++ b/src/main/kotlin/kr/co/vividnext/sodalive/content/comment/AudioContentCommentService.kt @@ -67,14 +67,18 @@ class AudioContentCommentService( val audioContentComment = repository.findByIdOrNull(request.commentId) ?: throw SodaException("잘못된 접근 입니다.\n확인 후 다시 시도해 주세요.") - if (audioContentComment.audioContent!!.member!!.id!! != member.id!!) { - if (audioContentComment.member == null || audioContentComment.member!!.id!! != member.id!!) { - throw SodaException("잘못된 접근 입니다.\n확인 후 다시 시도해 주세요.") - } + if ( + audioContentComment.member == null || + ( + audioContentComment.member!!.id!! != member.id!! && + audioContentComment.audioContent!!.member!!.id!! != member.id!! + ) + ) { + throw SodaException("잘못된 접근 입니다.\n확인 후 다시 시도해 주세요.") + } - if (request.comment != null) { - audioContentComment.comment = request.comment - } + if (request.comment != null) { + audioContentComment.comment = request.comment } if (request.isActive != null) {