From e8f909035a62adc57f3906e8697801ac63063d60 Mon Sep 17 00:00:00 2001 From: Yu Sung Date: Mon, 24 Mar 2025 21:27:24 +0900 Subject: [PATCH] =?UTF-8?q?=EB=9D=BC=EC=9D=B4=EB=B8=8C,=20=EC=BD=98?= =?UTF-8?q?=ED=85=90=EC=B8=A0=20=EB=A9=94=EC=9D=B8=20=ED=99=88=20-=20?= =?UTF-8?q?=ED=81=AC=EB=A6=AC=EC=97=90=EC=9D=B4=ED=84=B0=EC=9D=98=20?= =?UTF-8?q?=EA=B2=BD=EC=9A=B0=20=EB=9D=BC=EC=9D=B4=EB=B8=8C=20=EB=A7=8C?= =?UTF-8?q?=EB=93=A4=EA=B8=B0=20/=20=EC=BD=98=ED=85=90=EC=B8=A0=20?= =?UTF-8?q?=EC=97=85=EB=A1=9C=EB=93=9C=20=20=EB=B2=84=ED=8A=BC=EC=9D=B4=20?= =?UTF-8?q?=EB=B0=94=EB=A1=9C=20=EB=B3=B4=EC=9D=B4=EB=8F=84=EB=A1=9D=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Sources/Content/Main/V2/Home/ContentMainTabHomeView.swift | 3 ++- SodaLive/Sources/Live/LiveView.swift | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/SodaLive/Sources/Content/Main/V2/Home/ContentMainTabHomeView.swift b/SodaLive/Sources/Content/Main/V2/Home/ContentMainTabHomeView.swift index f22d38d..19a0393 100644 --- a/SodaLive/Sources/Content/Main/V2/Home/ContentMainTabHomeView.swift +++ b/SodaLive/Sources/Content/Main/V2/Home/ContentMainTabHomeView.swift @@ -11,6 +11,7 @@ struct ContentMainTabHomeView: View { @StateObject var viewModel = ContentMainTabHomeViewModel() @AppStorage("token") private var token: String = UserDefaults.string(forKey: UserDefaultsKey.token) + @AppStorage("role") private var role: String = UserDefaults.string(forKey: UserDefaultsKey.role) var body: some View { BaseView(isLoading: $viewModel.isLoading) { @@ -274,7 +275,7 @@ struct ContentMainTabHomeView: View { } } - if UserDefaults.string(forKey: .role) == MemberRole.CREATOR.rawValue { + if role == MemberRole.CREATOR.rawValue { HStack(spacing: 5) { Image("ic_thumb_play") .resizable() diff --git a/SodaLive/Sources/Live/LiveView.swift b/SodaLive/Sources/Live/LiveView.swift index 786a044..6a7b686 100644 --- a/SodaLive/Sources/Live/LiveView.swift +++ b/SodaLive/Sources/Live/LiveView.swift @@ -13,6 +13,7 @@ struct LiveView: View { @StateObject var viewModel = LiveViewModel() @StateObject var appState = AppState.shared @AppStorage("token") private var token: String = UserDefaults.string(forKey: UserDefaultsKey.token) + @AppStorage("role") private var role: String = UserDefaults.string(forKey: UserDefaultsKey.role) var body: some View { ZStack { @@ -124,7 +125,7 @@ struct LiveView: View { viewModel.getSummary() } - if !appState.isShowPlayer && UserDefaults.string(forKey: .role) == MemberRole.CREATOR.rawValue { + if !appState.isShowPlayer && role == MemberRole.CREATOR.rawValue { Image("btn_make_live") .padding(.trailing, 16) .padding(.bottom, 16)