Skip to content

Commit

Permalink
clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
ZeWaka committed Jul 8, 2024
1 parent 92c2934 commit eaeaa8b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -443,14 +443,14 @@ pub fn read_necessary_u32_config(source: &yaml_rust2::yaml::Yaml, index: &str) -
bail!("Undefined value for {}. This is a necessary config. Please check config.yaml in the examples folder for documentation.", index);
};

return match source[index].as_i64() {
match source[index].as_i64() {
Some(thing) => Ok(thing as u32),
None => bail!(
"Unlawful value for {}, not a proper number: ({:?})",
index,
source[index]
),
};
}
}

pub fn read_some_string_config(source: &yaml_rust2::yaml::Yaml, index: &str) -> Option<String> {
Expand Down

0 comments on commit eaeaa8b

Please sign in to comment.