Skip to content

Commit

Permalink
Merge branch 'develop' into feature/#48-hackerton
Browse files Browse the repository at this point in the history
  • Loading branch information
jiwon2724 authored Aug 25, 2024
2 parents 2144f5c + bc063ac commit 9bc20dd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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)
}
Expand Down Expand Up @@ -114,7 +114,6 @@ class LoginViewModel @Inject constructor(
)
) {
is PokitResult.Success -> {
Log.d("!!: ", authType)
tokenUseCase.setAuthType(authType)
_signUpState.emit(SignUpState.SignUp)
}
Expand Down

0 comments on commit 9bc20dd

Please sign in to comment.