1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-08-01 20:05:23 +02:00

chore(jsoniter): remove leftover code EE-6702 (#11984)

This commit is contained in:
andres-portainer 2024-06-28 09:46:49 -03:00 committed by GitHub
parent e1648425ea
commit 9c4935286f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 11 additions and 37 deletions

View file

@ -132,19 +132,6 @@ func (tx *DbTransaction) GetAll(bucketName string, obj interface{}, appendFn fun
})
}
func (tx *DbTransaction) GetAllWithJsoniter(bucketName string, obj interface{}, appendFn func(o interface{}) (interface{}, error)) error {
bucket := tx.tx.Bucket([]byte(bucketName))
return bucket.ForEach(func(k []byte, v []byte) error {
err := tx.conn.UnmarshalObject(v, obj)
if err == nil {
obj, err = appendFn(obj)
}
return err
})
}
func (tx *DbTransaction) GetAllWithKeyPrefix(bucketName string, keyPrefix []byte, obj interface{}, appendFn func(o interface{}) (interface{}, error)) error {
cursor := tx.tx.Bucket([]byte(bucketName)).Cursor()