Windows opts

This commit is contained in:
veeso 2021-11-09 14:58:57 +01:00
parent 9b9786bfbf
commit d9abb5545e

View file

@ -543,10 +543,9 @@ impl Localhost {
}),
false => {
// Is File
let extension: Option<String> = match path.extension() {
Some(s) => Some(String::from(s.to_str().unwrap_or(""))),
None => None,
};
let extension: Option<String> = path
.extension()
.map(|s| String::from(s.to_str().unwrap_or("")));
FsEntry::File(FsFile {
name: file_name,
abs_path: path.clone(),