Avoids bug on creating the live set in the IO thread.

This commit is contained in:
Vitor Pamplona
2023-11-30 14:50:24 -05:00
parent b021920eaa
commit 35c780f81b
@@ -109,6 +109,10 @@ class AccountStateViewModel() : ViewModel() {
}
viewModelScope.launch(Dispatchers.IO) {
withContext(Dispatchers.Main) {
// Prepares livedata objects on the main user.
account.userProfile().live()
}
serviceManager?.restartIfDifferentAccount(account)
}