Skip to content

Commit

Permalink
스플래시 화면 딜레이 500ms 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
easyhooon committed Nov 15, 2023
1 parent 27c4303 commit b093129
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import com.last.psychat.android.core.domain.usecase.login.SetLoginTokenUseCase
import com.last.psychat.android.core.ui.UiText
import dagger.hilt.android.lifecycle.HiltViewModel
import javax.inject.Inject
import kotlinx.coroutines.delay
import kotlinx.coroutines.flow.MutableSharedFlow
import kotlinx.coroutines.flow.MutableStateFlow
import kotlinx.coroutines.flow.SharedFlow
Expand Down Expand Up @@ -41,7 +42,10 @@ class SplashViewModel @Inject constructor(
val eventFlow: SharedFlow<SplashUiEvent> = _eventFlow.asSharedFlow()

init {
checkLoginToken()
viewModelScope.launch {
delay(500)
checkLoginToken()
}
}

private fun checkLoginToken() {
Expand Down

0 comments on commit b093129

Please sign in to comment.