Skip to content

Commit 522d970

Browse files
fb-ikhlepitkoJohnTitor
authored andcommitted
Fixed an issue when 'require_literal_leading_dot' option is not considered by 'glob_with' method for path components
1 parent a0af270 commit 522d970

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -878,6 +878,9 @@ fn fill_todo(
878878
});
879879
match dirs {
880880
Ok(mut children) => {
881+
if options.require_literal_leading_dot {
882+
children.retain(|x| !x.file_name().unwrap().to_str().unwrap().starts_with("."));
883+
}
881884
children.sort_by(|p1, p2| p2.file_name().cmp(&p1.file_name()));
882885
todo.extend(children.into_iter().map(|x| Ok((x, idx))));
883886

0 commit comments

Comments
 (0)