diff options
author | Matthias Beyer <mail@beyermatthias.de> | 2019-12-23 12:51:54 +0100 |
---|---|---|
committer | Matthias Beyer <mail@beyermatthias.de> | 2019-12-23 12:51:54 +0100 |
commit | 31193c2bef934d26265673c91cbea0b64a53cd15 (patch) | |
tree | 105163b13ed6fcb43e655f233679cc5947cf0b7b /core/src/utils.rs | |
parent | 71ea078d4eb5d857680a69b01f7427ea43e2f5a2 (diff) |
Run cargo-fmt on codebasecargo-fmt
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Diffstat (limited to 'core/src/utils.rs')
-rw-r--r-- | core/src/utils.rs | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/core/src/utils.rs b/core/src/utils.rs index ebed85b..2d0fd17 100644 --- a/core/src/utils.rs +++ b/core/src/utils.rs @@ -2,15 +2,14 @@ //! //! Contains everything which doesn't has a better place //! to be put in. -use std::marker::Send; use std::fmt::Debug; +use std::marker::Send; use chrono; use futures::Future; - /// Type alias for an boxed future which is Send + 'static. -pub type SendBoxFuture<I, E> = Box<Future<Item=I, Error=E> + Send + 'static>; +pub type SendBoxFuture<I, E> = Box<Future<Item = I, Error = E> + Send + 'static>; /// Returns the current data time. pub fn now() -> chrono::DateTime<chrono::Utc> { @@ -25,9 +24,12 @@ pub trait ConstSwitch: Debug + Copy + Send + Sync + 'static { /// Struct implementing `ConstSwitch` with `ENABLED = true`. #[derive(Debug, Copy, Clone)] pub struct Enabled; -impl ConstSwitch for Enabled { const ENABLED: bool = true; } +impl ConstSwitch for Enabled { + const ENABLED: bool = true; +} /// Struct implementing `ConstSwitch` with `ENABLED = false`. #[derive(Debug, Copy, Clone)] pub struct Disabled; -impl ConstSwitch for Disabled { const ENABLED: bool = false; } - +impl ConstSwitch for Disabled { + const ENABLED: bool = false; +} |