Skip to content

Commit

Permalink
Merge pull request #21 from AdultOfNineteen/bug/issue-20
Browse files Browse the repository at this point in the history
[BUG] 회원 탈퇴 오류
  • Loading branch information
DongChyeon authored Jan 11, 2024
2 parents 459a47f + ba4c6e9 commit 49500e8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ import androidx.lifecycle.viewModelScope
import androidx.navigation.navOptions
import com.teamwiney.core.common.base.BaseViewModel
import com.teamwiney.core.common.navigation.HomeDestinations
import com.teamwiney.core.common.util.Constants.ACCESS_TOKEN
import com.teamwiney.core.common.util.Constants.DEVICE_ID
import com.teamwiney.core.common.util.Constants.REFRESH_TOKEN
import com.teamwiney.core.common.util.Constants.USER_ID
import com.teamwiney.data.network.adapter.ApiResult
import com.teamwiney.data.repository.auth.AuthRepository
Expand Down Expand Up @@ -191,6 +193,8 @@ class MyPageViewModel @Inject constructor(
updateState(currentState.copy(isLoading = false))
when (it) {
is ApiResult.Success -> {
dataStoreRepository.deleteStringValue(ACCESS_TOKEN)
dataStoreRepository.deleteStringValue(REFRESH_TOKEN)
postEffect(
MyPageContract.Effect.ShowBottomSheet(
MyPageContract.BottomSheet.WithdrawalComplete
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ fun MyPageWithdrawalConfirmScreen(
val activity = (LocalContext.current as? Activity)

LaunchedEffect(true) {
viewModel.updateWithdrawalReason("이유를 선택해주세요.")

effectFlow.collectLatest { effect ->
when (effect) {
is MyPageContract.Effect.NavigateTo -> {
Expand Down

0 comments on commit 49500e8

Please sign in to comment.