From df6e8111c7f63af45693db3eecdc69cdda48ea1c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Roth?= Date: Sun, 21 Apr 2024 15:30:48 +0200 Subject: [PATCH] fix golangci-lint errors --- deb/reflist.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/deb/reflist.go b/deb/reflist.go index e039de127..55588a998 100644 --- a/deb/reflist.go +++ b/deb/reflist.go @@ -786,7 +786,7 @@ func segmentIndexKey(prefix []byte, idx int) []byte { func (collection *RefListCollection) AllBucketDigests() (*RefListDigestSet, error) { digests := NewRefListDigestSet() - err := collection.db.ProcessByPrefix([]byte("F"), func(key []byte, value []byte) error { + err := collection.db.ProcessByPrefix([]byte("F"), func(key []byte, _ []byte) error { if !bytes.HasSuffix(key, []byte("-0000")) { // Ignore additional segments for the same digest. return nil @@ -818,7 +818,7 @@ func (collection *RefListCollection) AllBucketDigests() (*RefListDigestSet, erro // the bucket is no longer referenced by any saved reflists. func (collection *RefListCollection) UnsafeDropBucket(digest []byte, batch database.Batch) error { prefix := segmentPrefix(bucketDigestEncoding.EncodeToString(digest)) - return collection.db.ProcessByPrefix(prefix, func(key []byte, value []byte) error { + return collection.db.ProcessByPrefix(prefix, func(key []byte, _ []byte) error { return batch.Delete(key) }) } @@ -866,7 +866,7 @@ func (collection *RefListCollection) loadBuckets(sl *SplitRefList) error { if bucket == nil { bucket = NewPackageRefList() prefix := segmentPrefix(bucketDigestEncoding.EncodeToString(digest)) - err := collection.db.ProcessByPrefix(prefix, func(digest []byte, value []byte) error { + err := collection.db.ProcessByPrefix(prefix, func(_ []byte, value []byte) error { var l PackageRefList if err := l.Decode(append([]byte{}, value...)); err != nil { return err