aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/src/main/java/com/zeapo/pwdstore/autofill/oreo/FormField.kt4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/src/main/java/com/zeapo/pwdstore/autofill/oreo/FormField.kt b/app/src/main/java/com/zeapo/pwdstore/autofill/oreo/FormField.kt
index 2bfa5075..6435a83f 100644
--- a/app/src/main/java/com/zeapo/pwdstore/autofill/oreo/FormField.kt
+++ b/app/src/main/java/com/zeapo/pwdstore/autofill/oreo/FormField.kt
@@ -271,7 +271,7 @@ class FormField(
}
infix fun directlyPrecedes(that: Iterable<FormField>): Boolean {
- val firstIndex = that.map { it.index }.min() ?: return false
+ val firstIndex = that.map { it.index }.minOrNull() ?: return false
return index == firstIndex - 1
}
@@ -280,7 +280,7 @@ class FormField(
}
infix fun directlyFollows(that: Iterable<FormField>): Boolean {
- val lastIndex = that.map { it.index }.max() ?: return false
+ val lastIndex = that.map { it.index }.maxOrNull() ?: return false
return index == lastIndex + 1
}