diff --git a/core/src/services/memory/backend.rs b/core/src/services/memory/backend.rs index b7f850333a1f..ad9c6dfddf88 100644 --- a/core/src/services/memory/backend.rs +++ b/core/src/services/memory/backend.rs @@ -30,17 +30,15 @@ use serde::Deserialize; use self::raw::ConfigDeserializer; -//Config for memory. +///Config for memory. #[derive(Default, Deserialize)] #[serde(default)] #[non_exhaustive] - -pub struct MemoryConfig{ +pub struct MemoryConfig { //root of the backend. pub root: Option, } - /// In memory service support. (BTreeMap Based) #[doc = include_str!("docs.md")] #[derive(Default)] @@ -61,9 +59,9 @@ impl Builder for MemoryBuilder { type Accessor = MemoryBackend; fn from_map(map: HashMap) -> Self { - MemoryBuilder{ + MemoryBuilder { config: MemoryConfig::deserialize(ConfigDeserializer::new(map)) - .expect("config deserialize must succeed"), + .expect("config deserialize must succeed"), } }