aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorToby Vincent <tobyv13@gmail.com>2023-05-15 20:50:13 -0500
committerToby Vincent <tobyv13@gmail.com>2023-05-15 20:50:13 -0500
commit58d9ba42fba6c7fe9420b35b635c74bc01958698 (patch)
tree854c4d6042ddacfe02c9ef1ec2afe66299514088
parent8cf91b5d97e626b2aa22b4829196a4128d859b69 (diff)
fix: filter files from search results
-rw-r--r--src/search.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/search.rs b/src/search.rs
index 9f85f3a..a7e6315 100644
--- a/src/search.rs
+++ b/src/search.rs
@@ -32,6 +32,10 @@ impl Search {
tracing::debug!(?p, "Ignoring search directory");
None
}
+ Ok(p) if p.is_file() => {
+ tracing::error!(?p, "Ignoring file");
+ None
+ }
Ok(p) => Some(p),
Err(err) => {
tracing::error!(%err, "Ignoring errored path");