Merge branch 'beta' into codex/fix-failing-workflow-tests

This commit is contained in:
thePR0M3TH3AN
2025-05-21 19:48:56 -04:00
committed by GitHub

View File

@@ -107,8 +107,8 @@ fn main() -> Result<()> {
Commands::Restore { backup_path } => {
drop(conn);
if backup_path.exists() {
db::restore(&backup_path, &cfg.db_path).with_context(|| {
if backup_path.exists() { db::restore(&backup_path, &cfg.db_path)
.with_context(|| {
format!("Failed to restore DB from {}", backup_path.display())
})?;
} else {
@@ -118,9 +118,12 @@ fn main() -> Result<()> {
.file_name()
.and_then(|n| n.to_str())
.context("invalid backup file name")?;
manager.restore_from_backup(name).with_context(|| {
manager
.restore_from_backup(name)
.with_context(|| {
format!("Failed to restore DB from {}", backup_path.display())
})?;
}
println!("Restored DB from {}", backup_path.display());
db::open(&cfg.db_path).with_context(|| {