fix(#1013): make validate_groups private (only called by set_groups)
This commit is contained in:
parent
a8ee894429
commit
8c836039d3
1 changed files with 1 additions and 1 deletions
|
|
@ -72,7 +72,7 @@ pub fn write(map: &BTreeMap<String, Vec<String>>) -> std::io::Result<()> {
|
||||||
/// Validate a slice of group name strings against `ToolGroup::ALL`.
|
/// Validate a slice of group name strings against `ToolGroup::ALL`.
|
||||||
/// Returns `Ok(())` when all names are known, or `Err` listing the
|
/// Returns `Ok(())` when all names are known, or `Err` listing the
|
||||||
/// unrecognised names so callers can surface a useful error message.
|
/// unrecognised names so callers can surface a useful error message.
|
||||||
pub fn validate_groups(groups: &[String]) -> anyhow::Result<()> {
|
fn validate_groups(groups: &[String]) -> anyhow::Result<()> {
|
||||||
let valid: std::collections::BTreeSet<&str> =
|
let valid: std::collections::BTreeSet<&str> =
|
||||||
hive_sh4re::ToolGroup::ALL.iter().map(|g| g.as_str()).collect();
|
hive_sh4re::ToolGroup::ALL.iter().map(|g| g.as_str()).collect();
|
||||||
let unknown: Vec<&str> = groups
|
let unknown: Vec<&str> = groups
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue