diff --git a/rust-sdk/Cargo.toml b/rust-sdk/Cargo.toml index 4a443166b6..7f0ab29e30 100644 --- a/rust-sdk/Cargo.toml +++ b/rust-sdk/Cargo.toml @@ -23,11 +23,11 @@ features = ["lax_deserialize"] [dependencies.matrix-sdk-common] git = "https://github.com/matrix-org/matrix-rust-sdk/" -branch = "encryption-info" +branch = "corroded-android" [dependencies.matrix-sdk-crypto] git = "https://github.com/matrix-org/matrix-rust-sdk/" -branch = "encryption-info" +branch = "corroded-android" features = ["sled_cryptostore"] [dependencies.tokio] diff --git a/rust-sdk/src/machine.rs b/rust-sdk/src/machine.rs index 7478000f44..a6e16e60c5 100644 --- a/rust-sdk/src/machine.rs +++ b/rust-sdk/src/machine.rs @@ -20,7 +20,7 @@ use matrix_sdk_common::{ events::{room::encrypted::EncryptedEventContent, AnyMessageEventContent, EventContent}, identifiers::{DeviceKeyAlgorithm, RoomId, UserId}, uuid::Uuid, - UInt, + IncomingResponse, UInt, }; use matrix_sdk_crypto::{ @@ -168,10 +168,18 @@ impl OlmMachine { let response = response_from_string(&response_body); let response: OwnedResponse = match request_type { - RequestType::KeysUpload => KeysUploadResponse::try_from(response).map(Into::into), - RequestType::KeysQuery => KeysQueryResponse::try_from(response).map(Into::into), - RequestType::ToDevice => ToDeviceResponse::try_from(response).map(Into::into), - RequestType::KeysClaim => KeysClaimResponse::try_from(response).map(Into::into), + RequestType::KeysUpload => { + KeysUploadResponse::try_from_http_response(response).map(Into::into) + } + RequestType::KeysQuery => { + KeysQueryResponse::try_from_http_response(response).map(Into::into) + } + RequestType::ToDevice => { + ToDeviceResponse::try_from_http_response(response).map(Into::into) + } + RequestType::KeysClaim => { + KeysClaimResponse::try_from_http_response(response).map(Into::into) + } } .expect("Can't convert json string to response");