Skip to content

Commit

Permalink
fix: btrfs: restore was not properly reporting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
sloonz committed Nov 27, 2023
1 parent 6d6cadc commit 0d518b4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sources/btrfs.go
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ func (s *btrfsSource) RestoreBackup(targetDir string, backup uback.Backup, data
cmd.Stderr = os.Stderr
err := cmd.Run()
if err != nil {
return nil
return err
}

return os.Rename(path.Join(targetDir, "_tmp-"+backup.Snapshot.Name()), path.Join(targetDir, backup.Snapshot.Name()))
Expand Down

0 comments on commit 0d518b4

Please sign in to comment.