unify error and success handling in extractors

This commit is contained in:
theubusu
2026-02-17 18:34:46 +01:00
parent aa2249f024
commit 10dd854685
29 changed files with 58 additions and 100 deletions
+1 -4
View File
@@ -52,8 +52,7 @@ pub fn extract_pfl_upg(app_ctx: &AppContext, _ctx: Box<dyn Any>) -> Result<(), B
}
}
if key.is_none() {
println!("Sorry, this firmware is not supported!");
std::process::exit(1);
return Err("This firmware is not supported!".into());
}
//get key
@@ -142,8 +141,6 @@ pub fn extract_pfl_upg(app_ctx: &AppContext, _ctx: Box<dyn Any>) -> Result<(), B
println!("- Saved file!");
}
println!("\nExtraction finished!");
Ok(())
}