From 42644b765a096111fb4f4ee4c427d00483b88261 Mon Sep 17 00:00:00 2001 From: fdai7375 Date: Tue, 24 Jan 2023 11:19:34 +0100 Subject: [PATCH] refactoring: remove unneeded metadata call --- src/builtins/ls.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/builtins/ls.rs b/src/builtins/ls.rs index 0f0dac8..6f9e258 100644 --- a/src/builtins/ls.rs +++ b/src/builtins/ls.rs @@ -29,6 +29,7 @@ impl Builtin for Ls { continue; } }; + let file_name = entry.file_name().to_string_lossy().to_string(); let mut file_type = "unknown"; if metadata.file_type().is_dir() {