crypto: Allow most of the ReadOnlyDevice to be serialized.

master
Damir Jelić 2020-09-02 11:49:49 +02:00
parent 81b127b6e7
commit 4bab678e46
2 changed files with 3 additions and 2 deletions

View File

@ -26,7 +26,7 @@ matrix-sdk-common-macros = { version = "0.1.0", path = "../matrix_sdk_common_mac
matrix-sdk-common = { version = "0.1.0", path = "../matrix_sdk_common" }
olm-rs = { git = 'https://gitlab.gnome.org/jhaye/olm-rs/', features = ["serde"]}
serde = { version = "1.0.115", features = ["derive"] }
serde = { version = "1.0.115", features = ["derive", "rc"] }
serde_json = "1.0.57"
cjson = "0.1.1"
zeroize = { version = "1.1.0", features = ["zeroize_derive"] }

View File

@ -31,6 +31,7 @@ use matrix_sdk_common::{
events::{room::encrypted::EncryptedEventContent, EventType},
identifiers::{DeviceId, DeviceKeyAlgorithm, DeviceKeyId, EventEncryptionAlgorithm, UserId},
};
use serde::{Deserialize, Serialize};
use serde_json::{json, Value};
use tracing::warn;
@ -230,7 +231,7 @@ impl UserDevices {
}
}
#[derive(Debug, Clone, Copy, PartialEq)]
#[derive(Debug, Clone, Copy, PartialEq, Serialize, Deserialize)]
/// The local trust state of a device.
pub enum LocalTrust {
/// The device has been verified and is trusted.