fix: stabilize core error handling

Remove production panic and unwrap paths from core modules.

Propagate bookmark encryption failures, harden file watcher and temp mapped file handling, and clean up dead code in shared utilities.
This commit is contained in:
Christian Visintin
2026-04-19 01:54:46 +05:30
parent 0025b87b0f
commit bc4b096077
15 changed files with 365 additions and 325 deletions
+9 -3
View File
@@ -73,10 +73,16 @@ impl TryFrom<&Args> for RemoteArgs {
// set args based on hosts len
if hosts.len() == 1 {
remote_args.remote = hosts.pop().unwrap();
remote_args.remote = hosts
.pop()
.ok_or_else(|| String::from("Missing remote host configuration"))?;
} else if hosts.len() == 2 {
remote_args.host_bridge = hosts.pop().unwrap();
remote_args.remote = hosts.pop().unwrap();
remote_args.host_bridge = hosts
.pop()
.ok_or_else(|| String::from("Missing host-bridge configuration"))?;
remote_args.remote = hosts
.pop()
.ok_or_else(|| String::from("Missing remote host configuration"))?;
}
Ok(remote_args)