diff options
author | Hristo Venev <hristo@venev.name> | 2019-03-18 12:37:27 +0200 |
---|---|---|
committer | Hristo Venev <hristo@venev.name> | 2019-03-18 12:37:27 +0200 |
commit | 761a87cc6e64990b9dd0e235047e1d1e7c7d6971 (patch) | |
tree | 920eac8fe6cfc12890cac0f19c9a016ed2b7913b /src/config.rs | |
parent | ac554b8129d2c43d87a5a0abca6bd097d870fe6d (diff) |
Lint
Diffstat (limited to 'src/config.rs')
-rw-r--r-- | src/config.rs | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/src/config.rs b/src/config.rs index 6411b3a..833b546 100644 --- a/src/config.rs +++ b/src/config.rs @@ -1,10 +1,9 @@ -use ::std::collections::HashSet; -use ::serde_derive; use crate::ip::{Ipv4Set, Ipv6Set}; +use serde_derive; +use std::collections::HashSet; #[serde(deny_unknown_fields)] -#[derive(serde_derive::Serialize, serde_derive::Deserialize)] -#[derive(Clone, PartialEq, Eq, Debug)] +#[derive(serde_derive::Serialize, serde_derive::Deserialize, Clone, PartialEq, Eq, Debug)] pub struct Source { pub url: String, pub psk: Option<String>, @@ -13,8 +12,7 @@ pub struct Source { } #[serde(deny_unknown_fields)] -#[derive(serde_derive::Serialize, serde_derive::Deserialize)] -#[derive(Clone, PartialEq, Eq, Debug)] +#[derive(serde_derive::Serialize, serde_derive::Deserialize, Clone, PartialEq, Eq, Debug)] pub struct PeerConfig { #[serde(default = "default_min_keepalive")] pub min_keepalive: u32, @@ -25,8 +23,7 @@ pub struct PeerConfig { } #[serde(deny_unknown_fields)] -#[derive(serde_derive::Serialize, serde_derive::Deserialize)] -#[derive(Clone, PartialEq, Eq, Debug)] +#[derive(serde_derive::Serialize, serde_derive::Deserialize, Clone, PartialEq, Eq, Debug)] pub struct UpdateConfig { // Number of seconds between regular updates. #[serde(default = "default_refresh")] @@ -34,8 +31,7 @@ pub struct UpdateConfig { } #[serde(deny_unknown_fields)] -#[derive(serde_derive::Serialize, serde_derive::Deserialize)] -#[derive(Clone, Debug)] +#[derive(serde_derive::Serialize, serde_derive::Deserialize, Clone, Debug)] pub struct Config { pub ifname: String, #[serde(default = "default_wg_command")] |