diff --git a/src/util/regulation.rs b/src/util/regulation.rs index 493019a..26aa3e0 100644 --- a/src/util/regulation.rs +++ b/src/util/regulation.rs @@ -88,7 +88,7 @@ impl Regulation { for file in &res.files { let path = PathBuf::from_str(&file.name).unwrap(); - let file_name = path.file_stem().unwrap().to_str().unwrap(); + let file_name = path.file_stem().unwrap().to_str().unwrap().split("\\").last().expect("Could not find content at end of path"); let param_type = Param::from_str(file_name)?; params.insert(param_type, file.bytes.to_vec()); }