fix(#1013): make validate_groups private (only called by set_groups)

This commit is contained in:
damocles 2026-06-01 21:47:29 +02:00
commit 8c836039d3

View file

@ -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`.
/// Returns `Ok(())` when all names are known, or `Err` listing the
/// 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> =
hive_sh4re::ToolGroup::ALL.iter().map(|g| g.as_str()).collect();
let unknown: Vec<&str> = groups