bolthelper.go
func (b Bucket) OpenBucket(folders [][]byte, f func(Bucket) error) error {
	bb := b.Bucket
	for _, fld := range folders {
		bb = bb.Bucket(fld)
		if bb == nil {
			return nil
		}
	}
	return errorsp.WithStacks(f(Bucket{bb}))
}
func (b Bucket) OpenBucket(folders [][]byte, f func(Bucket) error) error {
	bb := b.Bucket
	for _, fld := range folders {
		bb = bb.Bucket(fld)
		if bb == nil {
			return nil
		}
	}
	return errorsp.WithStacks(f(Bucket{bb}))
}
func ( b Bucket ) OpenBucket ( folders [ ] [ ] byte , f func ( Bucket ) error ) error { bb := b . Bucket for _ , fld := range folders { bb = bb . Bucket ( fld ) if bb == nil { return nil } } return errorsp . WithStacks ( f ( Bucket { bb } ) ) }
// Bucket retrieves a nested bucket by name. Returns nil if the bucket
// does not exist. The bucket instance is only valid for the lifetime of
// the transaction. folders can be empty, in which case the b itself is
// sent to f.
Bucket retrieves a nested bucket by name . Returns nil if the bucket does not exist . The bucket instance is only valid for the lifetime of the transaction . folders can be empty in which case the b itself is sent to f .