mirror of
https://github.com/logos-messaging/libchat.git
synced 2026-04-02 01:23:11 +00:00
16 lines
334 B
Rust
16 lines
334 B
Rust
|
|
use libchat::ChatError;
|
||
|
|
|
||
|
|
#[derive(Debug)]
|
||
|
|
pub enum ClientError<D> {
|
||
|
|
Chat(ChatError),
|
||
|
|
/// Crypto state advanced but at least one envelope failed delivery.
|
||
|
|
/// Caller decides whether to retry.
|
||
|
|
Delivery(D),
|
||
|
|
}
|
||
|
|
|
||
|
|
impl<D> From<ChatError> for ClientError<D> {
|
||
|
|
fn from(e: ChatError) -> Self {
|
||
|
|
Self::Chat(e)
|
||
|
|
}
|
||
|
|
}
|