From 2256affd8f539ffdcb253dfa664d253f209da381 Mon Sep 17 00:00:00 2001 From: Matthias Reitinger Date: Tue, 3 Oct 2017 17:36:06 +0200 Subject: [PATCH] Fix extension comparison logic --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index fa253d7..7d0b044 100644 --- a/src/main.rs +++ b/src/main.rs @@ -309,7 +309,7 @@ fn scan(root: &Path, pattern: Arc, base: &Path, config: Arc) { // Filter out unwanted extensions. if let Some(ref filter_ext) = config.extension { let entry_ext = entry.path().extension().map(|e| e.to_string_lossy().to_lowercase()); - if entry_ext.map_or(false, |ext| ext != *filter_ext) { + if entry_ext.map_or(true, |ext| ext != *filter_ext) { return ignore::WalkState::Continue; } }