fix(viewmodel): reload server list when cache is empty before update

This commit is contained in:
zarazaex69
2026-04-11 13:05:50 +03:00
parent 732d7248af
commit cb4e3aab54
@@ -266,6 +266,9 @@ class MainViewModel(application: Application) : AndroidViewModel(application) {
updateListAction.value = -1
viewModelScope.launch(Dispatchers.Default) {
if (serversCache.isEmpty()) {
withContext(Dispatchers.Main) { reloadServerList() }
}
if (serversCache.isEmpty()) {
return@launch
}