How to wait response values in viewModelScope from two suspend functions

Advertisements I have code like viewModelScope.launch(exceptionHandler) { withContext(Dispatchers.IO){ val name = fetchName() //suspend fun val surname = fetchSurname() //suspend fun } //how to wait response from name and surname to use it in another call? //name and surname must be async } private suspend fun fetchName(): Name { return withContext(Dispatchers.IO) { //db } } private… Read More How to wait response values in viewModelScope from two suspend functions