fix(content-series): 차단 접근 오류 메시지 키를 분리한다

This commit is contained in:
2026-02-26 01:41:06 +09:00
parent 389727cdb5
commit e7252574d2
4 changed files with 29 additions and 2 deletions

View File

@@ -0,0 +1,17 @@
# 2026-02-26 콘텐츠/시리즈 상세 차단 오류메시지 수정
## 구현 체크리스트
- [x] 콘텐츠 상세(`getDetail`) 차단 예외 메시지 키를 전용 차단 키로 변경
- [x] 시리즈 상세(`getSeriesDetail`) 차단 예외 메시지 키를 전용 차단 키로 변경
- [x] `SodaMessageSource`에 콘텐츠/시리즈 차단 전용 메시지 키 추가
- [x] 정적 진단 및 테스트로 변경 영향 검증
## 검증 기록
### 1차 구현
- 무엇: `AudioContentService.getDetail`의 차단 예외 키를 `content.error.blocked_access`로 변경하고, `ContentSeriesService.getSeriesDetail`의 차단 예외 키를 `series.error.blocked_access`로 변경했다. `SodaMessageSource`에 두 키를 추가해 한국어 기준으로 각각 "콘텐츠 접근이 차단되었습니다.", "시리즈 접근이 차단되었습니다."를 반환하도록 반영했다.
- 왜: 기존에는 차단 상황에서도 `invalid_content_retry`/`invalid_series_retry`를 사용해 오류 의미가 모호했고, 요청 사항대로 차단 상황을 명확한 문구로 안내해야 했기 때문이다.
- 어떻게:
- `lsp_diagnostics` (`AudioContentService.kt`, `ContentSeriesService.kt`, `SodaMessageSource.kt`) 실행: 실패 (현재 실행 환경에 Kotlin LSP 미구성으로 `.kt` 진단 불가)
- `./gradlew test` 실행: 성공
- `./gradlew ktlintCheck` 실행: 성공
- `./gradlew build` 실행: 성공

View File

@@ -525,7 +525,7 @@ class AudioContentService(
?: throw SodaException(messageKey = "content.error.user_not_found")
if (isBlockedBetweenMembers(memberId = member.id!!, creatorId = creatorId)) {
throw SodaException(messageKey = "content.error.invalid_content_retry")
throw SodaException(messageKey = "content.error.blocked_access")
}
val creatorFollowing = explorerQueryRepository.getCreatorFollowing(

View File

@@ -247,7 +247,7 @@ class ContentSeriesService(
val isBlocked = blockMemberRepository.isBlocked(blockedMemberId = member.id!!, memberId = series.member!!.id!!) ||
blockMemberRepository.isBlocked(blockedMemberId = series.member!!.id!!, memberId = member.id!!)
if (isBlocked) {
throw SodaException(messageKey = "series.error.invalid_series_retry")
throw SodaException(messageKey = "series.error.blocked_access")
}
val creatorFollowing = explorerQueryRepository.getCreatorFollowing(

View File

@@ -103,6 +103,11 @@ class SodaMessageSource {
Lang.EN to "Access to content is restricted at %s's request.",
Lang.JA to "%sさんの要請によりコンテンツへのアクセスが制限されています。"
),
"content.error.blocked_access" to mapOf(
Lang.KO to "콘텐츠 접근이 차단되었습니다.",
Lang.EN to "Content access is blocked.",
Lang.JA to "コンテンツへのアクセスがブロックされました。"
),
"content.error.pin_available_after_open" to mapOf(
Lang.KO to "콘텐츠 오픈 후 채널에 고정이 가능합니다.",
Lang.EN to "You can pin it to the channel after the content is opened.",
@@ -261,6 +266,11 @@ class SodaMessageSource {
Lang.KO to "잘못된 시리즈 입니다.\n다시 시도해 주세요",
Lang.EN to "Invalid series.\nPlease try again.",
Lang.JA to "不正なシリーズです。\nもう一度お試しください。"
),
"series.error.blocked_access" to mapOf(
Lang.KO to "시리즈 접근이 차단되었습니다.",
Lang.EN to "Series access is blocked.",
Lang.JA to "シリーズへのアクセスがブロックされました。"
)
)