From 1380af4f005ee5f34607db5cbb6705f93048b85a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Damir=20Jeli=C4=87?= Date: Wed, 29 May 2024 13:02:59 +0200 Subject: [PATCH] bindings: Even more precise errors for the QR code login --- bindings/matrix-sdk-ffi/src/client_builder.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bindings/matrix-sdk-ffi/src/client_builder.rs b/bindings/matrix-sdk-ffi/src/client_builder.rs index 7c6d520d9..02900ef6f 100644 --- a/bindings/matrix-sdk-ffi/src/client_builder.rs +++ b/bindings/matrix-sdk-ffi/src/client_builder.rs @@ -112,12 +112,12 @@ impl From for HumanQrLoginError { } QRCodeLoginError::SecureChannel(e) => match e { SecureChannelError::Utf8(_) - | SecureChannelError::Ecies(_) | SecureChannelError::MessageDecode(_) | SecureChannelError::Json(_) - | SecureChannelError::SecureChannelMessage { .. } - | SecureChannelError::InvalidCheckCode | SecureChannelError::RendezvousChannel(_) => HumanQrLoginError::Unknown, + SecureChannelError::SecureChannelMessage { .. } + | SecureChannelError::Ecies(_) + | SecureChannelError::InvalidCheckCode => HumanQrLoginError::ConnectionInsecure, SecureChannelError::InvalidIntent => HumanQrLoginError::OtherDeviceNotSignedIn, },