Use .into_iter() method on array to avoid dereference

This commit is contained in:
Aramis Razzaghipour 2021-11-03 16:13:47 +11:00
parent 04f03a360a
commit 16d38ec8b8
No known key found for this signature in database
GPG key ID: F788F7E990136003

View file

@ -50,8 +50,8 @@ fn fix_path_for_mac() -> Result<()> {
};
[ROOT_DIR, &home_dir]
.iter()
.map(|dir| String::from(*dir) + COMMON_APP_PATH)
.into_iter()
.map(|dir| dir.to_string() + COMMON_APP_PATH)
.map(PathBuf::from)
.filter(|path| path.exists())
.collect()