fix(content): 성인 콘텐츠 설정 동기화와 국가별 인증 분기를 적용한다
This commit is contained in:
@@ -44,7 +44,14 @@ struct HomeTabView: View {
|
||||
AppState.shared.setAppStep(step: .login)
|
||||
return
|
||||
}
|
||||
if auth == false {
|
||||
|
||||
let normalizedCountryCode = UserDefaults
|
||||
.string(forKey: .countryCode)
|
||||
.trimmingCharacters(in: .whitespacesAndNewlines)
|
||||
.uppercased()
|
||||
let isKoreanCountry = normalizedCountryCode.isEmpty || normalizedCountryCode == "KR"
|
||||
|
||||
if isKoreanCountry && auth == false {
|
||||
pendingAction = {
|
||||
AppState.shared
|
||||
.setAppStep(step: .characterDetail(characterId: characterId))
|
||||
@@ -52,6 +59,15 @@ struct HomeTabView: View {
|
||||
isShowAuthConfirmView = true
|
||||
return
|
||||
}
|
||||
|
||||
if !UserDefaults.isAdultContentVisible() {
|
||||
pendingAction = nil
|
||||
AppState.shared.errorMessage = I18n.Settings.adultContentEnableGuide
|
||||
AppState.shared.isShowErrorPopup = true
|
||||
AppState.shared.setAppStep(step: .contentViewSettings)
|
||||
return
|
||||
}
|
||||
|
||||
AppState.shared.setAppStep(step: .characterDetail(characterId: characterId))
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user