Skip to content

Commit

Permalink
ls: add missing error handling
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelEischer committed Feb 3, 2025
1 parent c32613a commit 6cc06e0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cmd/restic/cmd_ls.go
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,9 @@ func (p *sortedPrinter) Close() error {
slices.Reverse(p.collector)
}
for _, elem := range p.collector {
_ = p.printer.Node(elem.nodepath, elem.node, false)
if err := p.printer.Node(elem.nodepath, elem.node, false); err != nil {
return err
}
}
return nil
}
Expand Down

0 comments on commit 6cc06e0

Please sign in to comment.