1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-29 20:17:45 +00:00

ls: replace redundant closure with function itself

This commit is contained in:
Jeffrey Finkelstein 2021-10-01 22:27:01 -04:00
parent b2fa51ddd9
commit d013461a6f

View file

@ -1967,11 +1967,7 @@ fn display_file_name(
#[cfg(unix)] #[cfg(unix)]
{ {
if config.format != Format::Long && config.inode { if config.format != Format::Long && config.inode {
name = path name = path.md().map_or_else(|| "?".to_string(), get_inode) + " " + &name;
.md()
.map_or_else(|| "?".to_string(), |md| get_inode(md))
+ " "
+ &name;
} }
} }