pass context to Find / FindSnapshot

This allows proper interruption of restic while it searches for
snapshots or key files.
This commit is contained in:
Michael Eischer
2020-10-09 22:37:56 +02:00
parent 5fd3dbccb7
commit c458e114d4
13 changed files with 24 additions and 24 deletions
+1 -1
View File
@@ -53,7 +53,7 @@ func init() {
}
func loadSnapshot(ctx context.Context, repo *repository.Repository, desc string) (*restic.Snapshot, error) {
id, err := restic.FindSnapshot(repo, desc)
id, err := restic.FindSnapshot(ctx, repo, desc)
if err != nil {
return nil, err
}