diff options
author | Quentin Dufour <quentin@deuxfleurs.fr> | 2022-06-22 17:26:52 +0200 |
---|---|---|
committer | Quentin Dufour <quentin@deuxfleurs.fr> | 2022-06-22 17:26:52 +0200 |
commit | cea27474f9dfed289be4e7be017913d7165342f3 (patch) | |
tree | 6e971a12acfe82a2dca9d39d2cd36bafe3e59c6d /src/imap/flow.rs | |
parent | ac974184def76fefba6c36c5c9e0ff0298f860ff (diff) | |
download | aerogramme-cea27474f9dfed289be4e7be017913d7165342f3.tar.gz aerogramme-cea27474f9dfed289be4e7be017913d7165342f3.zip |
cargo fmt
Diffstat (limited to 'src/imap/flow.rs')
-rw-r--r-- | src/imap/flow.rs | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/src/imap/flow.rs b/src/imap/flow.rs index 9a2a2ba..f0ec7d1 100644 --- a/src/imap/flow.rs +++ b/src/imap/flow.rs @@ -1,5 +1,5 @@ -use std::fmt; use std::error::Error as StdError; +use std::fmt; use crate::login::Credentials; use crate::mailbox::Mailbox; @@ -14,26 +14,25 @@ pub enum Error { ForbiddenTransition, } impl fmt::Display for Error { - fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { - write!(f, "Forbidden Transition") - } + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + write!(f, "Forbidden Transition") + } } -impl StdError for Error { } - +impl StdError for Error {} pub enum State { NotAuthenticated, Authenticated(User), Selected(User, Mailbox), - Logout + Logout, } pub enum Transition { - No, - Authenticate(User), - Select(Mailbox), - Unselect, - Logout, + No, + Authenticate(User), + Select(Mailbox), + Unselect, + Logout, } // See RFC3501 section 3. @@ -50,4 +49,3 @@ impl State { } } } - |