diff --git a/crates/matrix-sdk-indexeddb/src/crypto_store/indexeddb_serializer.rs b/crates/matrix-sdk-indexeddb/src/crypto_store/indexeddb_serializer.rs index 6237403bb..40dde29cb 100644 --- a/crates/matrix-sdk-indexeddb/src/crypto_store/indexeddb_serializer.rs +++ b/crates/matrix-sdk-indexeddb/src/crypto_store/indexeddb_serializer.rs @@ -39,6 +39,24 @@ pub struct IndexeddbSerializer { store_cipher: Option>, } +#[allow(dead_code)] +#[derive(Debug, thiserror::Error)] +pub enum IndexeddbSerializerError { + #[error(transparent)] + Serialization(#[from] serde_json::Error), + #[error("DomException {name} ({code}): {message}")] + DomException { + /// DomException code + code: u16, + /// Specific name of the DomException + name: String, + /// Message given to the DomException + message: String, + }, + #[error(transparent)] + CryptoStoreError(#[from] CryptoStoreError), +} + #[derive(Debug, Deserialize, Serialize)] #[serde(untagged)] pub enum MaybeEncrypted {