Skip to main content

validate_user_path

Function validate_user_path 

Source
pub fn validate_user_path(
    path: &str,
    field: &'static str,
) -> Result<(), GlobValidationError>
Expand description

Validate a user-supplied DIRECTORY PATH (not a glob). Same absolute-path and traversal checks as compile_user_glob, but skips the glob-syntax check because the value is a literal path, not a pattern.

Used for fields like boundaries.zones[].root and boundaries.zones[].autoDiscover that name a directory subtree rather than a match pattern.

ยงErrors

Returns AbsolutePath or TraversalSegment for the same shapes compile_user_glob rejects. Never returns InvalidSyntax.