boltstore/store/config.go

19 lines
383 B
Go
Raw Normal View History

2014-06-14 20:15:10 +04:00
package store
2014-06-13 22:36:36 +04:00
2014-06-14 20:15:10 +04:00
import (
2016-02-18 12:08:51 +03:00
"github.com/admpub/boltstore/shared"
2014-06-14 20:15:10 +04:00
)
2014-06-13 22:36:36 +04:00
// Config represents a config for a session store.
type Config struct {
2014-06-18 06:50:40 +04:00
// DBOptions represents options for a database.
DBOptions Options
2014-06-13 22:36:36 +04:00
}
// setDefault sets default to the config.
func (c *Config) setDefault() {
if c.DBOptions.BucketName == nil {
2014-06-14 20:15:10 +04:00
c.DBOptions.BucketName = []byte(shared.DefaultBucketName)
2014-06-13 22:36:36 +04:00
}
}