Fix isLoading live data

pull/149/head
Koitharu 4 years ago
parent 3c739eed8e
commit 83eb0d9f23
No known key found for this signature in database
GPG Key ID: 8E861F8CE6E7CE27

@ -13,8 +13,8 @@ class CountedBooleanLiveData : MutableLiveData<Boolean>(false) {
counter--
}
val newValue = counter > 0
if (newValue != value) {
super.setValue(value)
if (newValue != this.value) {
super.setValue(newValue)
}
}
}

@ -137,6 +137,9 @@ class RemoteListViewModel(
e.printStackTrace()
}
listError.value = e
if (!mangaList.value.isNullOrEmpty()) {
onError.postCall(e)
}
}
}
}

Loading…
Cancel
Save