diff --git a/data/src/main/java/pokitmons/pokit/data/repository/auth/AuthRepositoryImpl.kt b/data/src/main/java/pokitmons/pokit/data/repository/auth/AuthRepositoryImpl.kt index 8344d0b6..d795df94 100644 --- a/data/src/main/java/pokitmons/pokit/data/repository/auth/AuthRepositoryImpl.kt +++ b/data/src/main/java/pokitmons/pokit/data/repository/auth/AuthRepositoryImpl.kt @@ -1,8 +1,8 @@ package pokitmons.pokit.data.repository.auth import android.util.Log -import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.first +import kotlinx.coroutines.flow.Flow import pokitmons.pokit.data.datasource.local.TokenManager import pokitmons.pokit.data.datasource.remote.auth.AuthDataSource import pokitmons.pokit.data.mapper.auth.AuthMapper diff --git a/feature/login/src/main/java/pokitmons/pokit/LoginViewModel.kt b/feature/login/src/main/java/pokitmons/pokit/LoginViewModel.kt index b041dde8..ccde135b 100644 --- a/feature/login/src/main/java/pokitmons/pokit/LoginViewModel.kt +++ b/feature/login/src/main/java/pokitmons/pokit/LoginViewModel.kt @@ -77,13 +77,13 @@ class LoginViewModel @Inject constructor( when (loginResult) { is PokitResult.Success -> { + authType = authPlatform when (loginResult.result.isRegistered) { true -> { tokenUseCase.apply { setAccessToken(loginResult.result.accessToken) setRefreshToken(loginResult.result.refreshToken) setAuthType(authType) - Log.d("!! : ", getAuthType().first().toString()) } _loginState.emit(LoginState.Registered) } @@ -114,7 +114,6 @@ class LoginViewModel @Inject constructor( ) ) { is PokitResult.Success -> { - Log.d("!!: ", authType) tokenUseCase.setAuthType(authType) _signUpState.emit(SignUpState.SignUp) }