summaryrefslogtreecommitdiffhomepage
path: root/android
diff options
context:
space:
mode:
authorJanito Vaqueiro Ferreira Filho <janito@mullvad.net>2021-02-05 20:45:27 +0000
committerJanito Vaqueiro Ferreira Filho <janito@mullvad.net>2021-02-08 15:30:37 +0000
commitee1eab3ebb1bb57cd6b02d63220d73dcef51d12b (patch)
treea9dc72c806156b3e483ac6e2dca1e423b4f317c0 /android
parent04d9870967fb9fc6462c0b9040e99f629219c035 (diff)
downloadmullvadvpn-ee1eab3ebb1bb57cd6b02d63220d73dcef51d12b.tar.xz
mullvadvpn-ee1eab3ebb1bb57cd6b02d63220d73dcef51d12b.zip
Refactor to name the callback parameter
Diffstat (limited to 'android')
-rw-r--r--android/src/main/kotlin/net/mullvad/mullvadvpn/ui/customdns/EditCustomDnsServerHolder.kt6
1 files changed, 3 insertions, 3 deletions
diff --git a/android/src/main/kotlin/net/mullvad/mullvadvpn/ui/customdns/EditCustomDnsServerHolder.kt b/android/src/main/kotlin/net/mullvad/mullvadvpn/ui/customdns/EditCustomDnsServerHolder.kt
index fcb43bbd5f..5c0c436a8a 100644
--- a/android/src/main/kotlin/net/mullvad/mullvadvpn/ui/customdns/EditCustomDnsServerHolder.kt
+++ b/android/src/main/kotlin/net/mullvad/mullvadvpn/ui/customdns/EditCustomDnsServerHolder.kt
@@ -70,9 +70,9 @@ class EditCustomDnsServerHolder(view: View, adapter: CustomDnsAdapter) : CustomD
init {
view.findViewById<View>(R.id.save).setOnClickListener {
- adapter.saveDnsServer(input.text.toString(), onFailCallback) {
- state = State.Error
- }
+ val onFailCallback = { state = State.Error }
+
+ adapter.saveDnsServer(input.text.toString(), onFailCallback)
}
}
}