From 3c9a675b9d776bf2210803d582e9af88f9df2631 Mon Sep 17 00:00:00 2001 From: Akshay Date: Thu, 28 Oct 2021 07:50:36 +0530 Subject: fix fp with manual_inherit and manual_inherit_from the lint also needed to validate if the length of the path component was exactly one, and not just check if the first component matches the value. --- bin/src/main.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'bin/src/main.rs') diff --git a/bin/src/main.rs b/bin/src/main.rs index 9e9c8ac..c5d0626 100644 --- a/bin/src/main.rs +++ b/bin/src/main.rs @@ -60,7 +60,12 @@ fn _main() -> Result<(), StatixErr> { let src = if let Some(path) = &single_config.target { std::fs::read_to_string(&path).map_err(SingleFixErr::InvalidPath)? } else { - io::stdin().lock().lines().map(|l| l.unwrap()).collect::>().join("\n") + io::stdin() + .lock() + .lines() + .map(|l| l.unwrap()) + .collect::>() + .join("\n") }; let path_id = if let Some(path) = &single_config.target { -- cgit v1.2.3