Updated on 2026-08-14
This commit is contained in:
parent
1b3ad50ef2
commit
19646fdb03
2 changed files with 16 additions and 5 deletions
|
|
@ -35,10 +35,17 @@ internal class SaltPayRegistrationErrorConverter(
|
|||
message = context.getString(R.string.saltpay_error_pin_weak_message),
|
||||
)
|
||||
}
|
||||
else -> ConvertedDialogMessage(
|
||||
title = context.getString(R.string.common_error),
|
||||
message = saltPayError.message,
|
||||
)
|
||||
else -> {
|
||||
val errorMessage = if (saltPayError.message == SaltPayRegistrationError.EMPTY_MESSAGE) {
|
||||
saltPayError::class.java.simpleName
|
||||
} else {
|
||||
saltPayError.message
|
||||
}
|
||||
ConvertedDialogMessage(
|
||||
title = context.getString(R.string.common_error),
|
||||
message = errorMessage,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
return dialogMessage
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ sealed class SaltPayRegistrationError(
|
|||
override val data: Any? = null,
|
||||
) : SaltPayModuleError(
|
||||
subCode = ERROR_CODE_REGISTRATION + subCode,
|
||||
message = message ?: this::class.java.simpleName,
|
||||
message = message ?: EMPTY_MESSAGE,
|
||||
) {
|
||||
object Unknown : SaltPayRegistrationError(4)
|
||||
object Empty : SaltPayRegistrationError(4)
|
||||
|
|
@ -44,4 +44,8 @@ sealed class SaltPayRegistrationError(
|
|||
object EmptyDynamicAttestResponse : SaltPayRegistrationError(11)
|
||||
object EmptyBackupCardScanned : SaltPayRegistrationError(12) //
|
||||
object WeakPin : SaltPayRegistrationError(13) //
|
||||
|
||||
companion object {
|
||||
const val EMPTY_MESSAGE = ""
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue