Skip to content

Commit ddeeec6

Browse files
Update src/utils.rs
Co-authored-by: Rene Leonhardt <[email protected]>
1 parent 8641923 commit ddeeec6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/utils.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#[inline(always)]
22
pub(crate) fn get_home_dir() -> Option<String> {
3-
std::env::home_dir().map(|v| v.to_string_lossy().to_string())
3+
std::env::home_dir().and_then(|v| v.to_str().map(String::from))
44
}
55

66
// This function is required when `glob_tilde_expansion` field of `glob::MatchOptions` is

0 commit comments

Comments
 (0)