fix the warnings

This commit is contained in:
glitchySid
2026-01-09 17:45:13 +05:30
parent ba0ea3f221
commit b6db79774a

View File

@@ -12,9 +12,9 @@ impl FileBatch {
let mut filenames = Vec::new();
let mut paths = Vec::new();
let walker = if recursive {
WalkDir::new(&root_path).min_depth(1).follow_links(false)
WalkDir::new(root_path).min_depth(1).follow_links(false)
} else {
WalkDir::new(&root_path)
WalkDir::new(root_path)
.min_depth(1)
.max_depth(1)
.follow_links(false)
@@ -22,7 +22,7 @@ impl FileBatch {
for entry in walker.into_iter().filter_map(|e| e.ok()) {
let path = entry.path();
if path.is_file() {
match path.strip_prefix(&root_path) {
match path.strip_prefix(root_path) {
Ok(relative_path) => {
filenames.push(relative_path.to_string_lossy().into_owned());
paths.push(path.to_path_buf());