mirror of
https://github.com/restic/restic.git
synced 2025-10-11 03:12:38 +00:00
copy/find/ls/recover/stats: Memorize snapshot listing before index
These commands filter the snapshots according to some criteria which essentially requires loading the index before filtering the snapshots. Thus create a copy of the snapshots list beforehand and use it later on.
This commit is contained in:
@@ -223,7 +223,7 @@ func updateSnapshots(ctx context.Context, root *Root) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
snapshots, err := restic.FindFilteredSnapshots(ctx, root.repo, root.cfg.Hosts, root.cfg.Tags, root.cfg.Paths)
|
||||
snapshots, err := restic.FindFilteredSnapshots(ctx, root.repo.Backend(), root.repo, root.cfg.Hosts, root.cfg.Tags, root.cfg.Paths)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
Reference in New Issue
Block a user