From 739c2011a71d129e1ddb86a653fcadc6420e56db Mon Sep 17 00:00:00 2001 From: cmal Date: Thu, 9 Aug 2018 11:55:27 +0200 Subject: [PATCH] Remove redundant filtering operation (optimization) --- components/site/src/lib.rs | 2 -- 1 file changed, 2 deletions(-) diff --git a/components/site/src/lib.rs b/components/site/src/lib.rs index da5f79d4..d2e198b5 100644 --- a/components/site/src/lib.rs +++ b/components/site/src/lib.rs @@ -187,7 +187,6 @@ impl Site { section_entries .into_par_iter() - .filter(|entry| entry.as_path().file_name().unwrap() == "_index.md") .map(|entry| { let path = entry.as_path(); Section::from_file(path, config) @@ -200,7 +199,6 @@ impl Site { page_entries .into_par_iter() - .filter(|entry| entry.as_path().file_name().unwrap() != "_index.md") .map(|entry| { let path = entry.as_path(); Page::from_file(path, config)