mirror of
https://github.com/nivekuil/rip
synced 2024-11-10 06:04:17 +00:00
Fix erroneous change to bury
This commit is contained in:
parent
98f5008728
commit
208ca3db68
1 changed files with 2 additions and 1 deletions
|
@ -271,7 +271,8 @@ fn bury<S: AsRef<Path>, D: AsRef<Path>>(source: S, dest: D) -> io::Result<()> {
|
|||
// Walk the source, creating directories and copying files as needed
|
||||
for entry in WalkDir::new(source).into_iter().filter_map(|e| e.ok()) {
|
||||
// Path without the top-level directory
|
||||
let orphan: &Path = &join_absolute(entry.path(), source);
|
||||
let orphan: &Path = entry.path().strip_prefix(source)
|
||||
.map_err(|err| io::Error::new(io::ErrorKind::Other, err))?;
|
||||
if entry.file_type().is_dir() {
|
||||
let mode = entry.metadata()?.permissions().mode();
|
||||
if let Err(e) = fs::DirBuilder::new()
|
||||
|
|
Loading…
Reference in a new issue