aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/src/util
diff options
context:
space:
mode:
Diffstat (limited to 'crates/shirabe/src/util')
-rw-r--r--crates/shirabe/src/util/filesystem.rs11
1 files changed, 5 insertions, 6 deletions
diff --git a/crates/shirabe/src/util/filesystem.rs b/crates/shirabe/src/util/filesystem.rs
index a12c6d64..2c4cbcc6 100644
--- a/crates/shirabe/src/util/filesystem.rs
+++ b/crates/shirabe/src/util/filesystem.rs
@@ -488,12 +488,11 @@ impl Filesystem {
let mut result = true;
for file in &ri {
- let target_path = format!(
- "{}{}{}",
- target,
- std::path::MAIN_SEPARATOR,
- ri.get_sub_pathname()
- );
+ let target_path = Path::new(&target)
+ .join(ri.get_sub_pathname())
+ .into_os_string()
+ .into_string()
+ .unwrap();
if file.is_dir() {
self.ensure_directory_exists(&target_path)?;
} else {