fmt: apply rustfmt

This commit is contained in:
2026-10-02 01:28:08 +02:00
parent 61b95c0ac1
commit 5e4b9cb231
+2 -10
View File
@@ -160,21 +160,13 @@ fn copy_file_times(src: &Path, dest: &Path) -> Result<(), Box<dyn Error>> {
fn component_addon(name: &str) -> Option<&str> {
let rest = name.split_once(".orig-")?.1;
let addon = rest.split(".tar.").next()?;
if addon.is_empty() {
None
} else {
Some(addon)
}
if addon.is_empty() { None } else { Some(addon) }
}
/// Move the contents of an archive's wrapper directory into `dir`, or into
/// `dir/<addon>` for a multi-orig component, replacing any pre-existing
/// addon directory.
fn unwrap_into(
dir: &Path,
wrapper: &Path,
addon: Option<&str>,
) -> Result<(), Box<dyn Error>> {
fn unwrap_into(dir: &Path, wrapper: &Path, addon: Option<&str>) -> Result<(), Box<dyn Error>> {
let target = match addon {
Some(addon) => {
let target = dir.join(addon);