Use LiveData instead of Observable

This commit is contained in:
topjohnwu
2022-05-29 03:57:32 -07:00
parent 0b5f973b31
commit c0981174a8
6 changed files with 13 additions and 27 deletions
@@ -70,7 +70,7 @@ class ModuleViewModel : BaseViewModel() {
}
fun downloadPressed(item: OnlineModule?) =
if (item != null && isConnected.get()) {
if (item != null && Info.isConnected.value == true) {
withExternalRW { ModuleInstallDialog(item).publish() }
} else {
SnackbarEvent(R.string.no_connection).publish()