fix(db): remove a bucket overwrite EE-4424 (#7867)

pull/7990/head
andres-portainer 2 years ago committed by GitHub
parent e82d0cfbdb
commit 49d02e0386
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -421,7 +421,6 @@ func (connection *DbConnection) BackupMetadata() (map[string]interface{}, error)
err := connection.View(func(tx *bolt.Tx) error {
err := tx.ForEach(func(name []byte, bucket *bolt.Bucket) error {
bucketName := string(name)
bucket = tx.Bucket([]byte(bucketName))
seqId := bucket.Sequence()
buckets[bucketName] = int(seqId)
return nil

@ -14,7 +14,6 @@ func backupMetadata(connection *bolt.DB) (map[string]interface{}, error) {
err := connection.View(func(tx *bolt.Tx) error {
err := tx.ForEach(func(name []byte, bucket *bolt.Bucket) error {
bucketName := string(name)
bucket = tx.Bucket([]byte(bucketName))
seqId := bucket.Sequence()
buckets[bucketName] = int(seqId)
return nil

Loading…
Cancel
Save