diff --git a/vector/src/main/java/im/vector/riotx/features/crypto/verification/SASVerificationActivity.kt b/vector/src/main/java/im/vector/riotx/features/crypto/verification/SASVerificationActivity.kt index 2c695cad6e..de10e8d3b2 100644 --- a/vector/src/main/java/im/vector/riotx/features/crypto/verification/SASVerificationActivity.kt +++ b/vector/src/main/java/im/vector/riotx/features/crypto/verification/SASVerificationActivity.kt @@ -97,8 +97,9 @@ class SASVerificationActivity : SimpleFragmentActivity() { } if (isIncoming) { - val incoming = viewModel.transaction as IncomingSasVerificationTransaction - when (incoming.uxState) { + val incoming = viewModel.transaction as? IncomingSasVerificationTransaction + when (incoming?.uxState) { + null, IncomingSasVerificationTransaction.UxState.UNKNOWN, IncomingSasVerificationTransaction.UxState.SHOW_ACCEPT, IncomingSasVerificationTransaction.UxState.WAIT_FOR_KEY_AGREEMENT -> {