Fix deprecation warning by writing better code

This commit is contained in:
Lucien Greathouse
2021-06-14 12:50:54 -04:00
parent 17fdd18c55
commit d3abca46a8

View File

@@ -34,7 +34,7 @@ pub fn copy_recursive(from: &Path, to: &Path) -> io::Result<()> {
Ok(_) => {}
Err(err) => match err.kind() {
io::ErrorKind::AlreadyExists => {}
_ => panic!(err),
_ => return Err(err),
},
}
} else {