diff --git a/src/config.rs b/src/config.rs index 0f76fde..ae6410d 100644 --- a/src/config.rs +++ b/src/config.rs @@ -50,6 +50,11 @@ impl Config { self } + /// Get the contents of an existing rule + pub fn get_rule(&self, id: usize) -> Option { + self.rules.get(&id.to_string()).cloned() + } + /// Add a new rule to the rule set by setting the retention age pub fn add_rule( &mut self,