diff --git a/vector/src/main/java/im/vector/app/features/onboarding/ftueauth/FtueMissingRegistrationStagesComparator.kt b/vector/src/main/java/im/vector/app/features/onboarding/ftueauth/FtueMissingRegistrationStagesComparator.kt index 6a6326625e..4d9fe10852 100644 --- a/vector/src/main/java/im/vector/app/features/onboarding/ftueauth/FtueMissingRegistrationStagesComparator.kt +++ b/vector/src/main/java/im/vector/app/features/onboarding/ftueauth/FtueMissingRegistrationStagesComparator.kt @@ -21,7 +21,7 @@ import org.matrix.android.sdk.api.auth.registration.Stage class FtueMissingRegistrationStagesComparator : Comparator { override fun compare(a: Stage?, b: Stage?): Int { - return (a?.toPriority() ?: 0) - (b?.toPriority() ?: 0) + return (a?.toPriority() ?: 0).compareTo(b?.toPriority() ?: 0) } private fun Stage.toPriority() = when (this) {