aboutsummaryrefslogtreecommitdiff
path: root/objectstore/packed/trailer_match.go
diff options
context:
space:
mode:
Diffstat (limited to 'objectstore/packed/trailer_match.go')
-rw-r--r--objectstore/packed/trailer_match.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/objectstore/packed/trailer_match.go b/objectstore/packed/trailer_match.go
index 25337cd7..dc43e37d 100644
--- a/objectstore/packed/trailer_match.go
+++ b/objectstore/packed/trailer_match.go
@@ -5,12 +5,12 @@ import "fmt"
// verifyPackMatchesIndexes checks that one opened pack's trailer hash matches
// every loaded index that references the same pack name.
func (store *Store) verifyPackMatchesIndexes(pack *packFile) error {
- err := store.ensureCandidates()
+ snapshot, err := store.ensureCandidates()
if err != nil {
return err
}
- candidate, ok := store.candidateForPack(pack.name)
+ candidate, ok := snapshot.candidateByPack[pack.name]
if !ok {
return fmt.Errorf("objectstore/packed: missing index for pack %q", pack.name)
}