diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/cli.rs | 4 | ||||
-rw-r--r-- | src/config.rs | 2 | ||||
-rw-r--r-- | src/finder/config.rs | 2 | ||||
-rw-r--r-- | src/logging/config.rs | 2 | ||||
-rw-r--r-- | src/paths/config.rs | 2 |
5 files changed, 6 insertions, 6 deletions
@@ -1,6 +1,6 @@ use crate::{paths::PathEntry, Config}; use clap::{Args, Parser}; -use figment::{providers::Serialized, value, Metadata, Profile, Provider}; +use figment::{value, Metadata, Profile, Provider}; use serde::Serialize; use std::path::PathBuf; use tracing::Level; @@ -41,7 +41,7 @@ impl Provider for Cli { } fn data(&self) -> figment::error::Result<value::Map<Profile, value::Dict>> { - Serialized::defaults(Self::default()).data() + Config::from(self.to_owned()).data() } } diff --git a/src/config.rs b/src/config.rs index afbb401..39c27fe 100644 --- a/src/config.rs +++ b/src/config.rs @@ -23,7 +23,7 @@ impl Provider for Config { } fn data(&self) -> figment::error::Result<value::Map<Profile, value::Dict>> { - Serialized::defaults(Self::default()).data() + Serialized::defaults(self).data() } } diff --git a/src/finder/config.rs b/src/finder/config.rs index 916637f..47a7eb6 100644 --- a/src/finder/config.rs +++ b/src/finder/config.rs @@ -43,7 +43,7 @@ impl Provider for Config { } fn data(&self) -> figment::error::Result<value::Map<Profile, value::Dict>> { - Serialized::defaults(Self::default()).data() + Serialized::defaults(self).data() } } diff --git a/src/logging/config.rs b/src/logging/config.rs index 8626a36..2f7be0f 100644 --- a/src/logging/config.rs +++ b/src/logging/config.rs @@ -31,7 +31,7 @@ impl Provider for Config { } fn data(&self) -> figment::error::Result<value::Map<Profile, value::Dict>> { - Serialized::defaults(Self::default()).data() + Serialized::defaults(self).data() } } diff --git a/src/paths/config.rs b/src/paths/config.rs index eea176f..4756d02 100644 --- a/src/paths/config.rs +++ b/src/paths/config.rs @@ -25,7 +25,7 @@ impl Provider for Config { } fn data(&self) -> figment::error::Result<value::Map<Profile, value::Dict>> { - Serialized::defaults(Self::default()).data() + Serialized::defaults(self).data() } } |