Compare commits
No commits in common. "v1.3.2" and "master" have entirely different histories.
10
redis.go
10
redis.go
@ -8,14 +8,4 @@ import (
|
||||
type Config = sentinel.Config
|
||||
|
||||
var NewPool = redis.NewPool
|
||||
var NewRedisPool = redis.NewPool
|
||||
var NewSentinelPool = sentinel.NewPool
|
||||
|
||||
func NewPool(cfg Config) *redis.Pool {
|
||||
if cfg.Master != "" {
|
||||
return NewRedisPool(cfg)
|
||||
} else if cfg.MasterName {
|
||||
return NewSentinelPool(cfg)
|
||||
}
|
||||
panic("invalid config: Master & MasterName are both empty")
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user