Show url dialog only if necessary

This commit is contained in:
topjohnwu 2020-01-18 03:59:02 +08:00
parent e4bcdbd0c4
commit cf161a5dd9

View File

@ -110,7 +110,7 @@ class SettingsViewModel(
private fun openUrlIfNecessary(view: View) { private fun openUrlIfNecessary(view: View) {
UpdateChannelUrl.refresh() UpdateChannelUrl.refresh()
if (UpdateChannelUrl.value.isBlank()) { if (UpdateChannelUrl.isEnabled && UpdateChannelUrl.value.isBlank()) {
UpdateChannelUrl.onPressed(view, this@SettingsViewModel) UpdateChannelUrl.onPressed(view, this@SettingsViewModel)
} }
} }