forked from mirror/redis
Fix example.
This commit is contained in:
parent
22e4776c1e
commit
95cd890e40
|
@ -29,14 +29,10 @@ func ExampleNewTCPClient() {
|
||||||
}
|
}
|
||||||
|
|
||||||
func ExampleNewFailoverClient() {
|
func ExampleNewFailoverClient() {
|
||||||
client := redis.NewFailoverClient(&redis.FailoverOptions{
|
redis.NewFailoverClient(&redis.FailoverOptions{
|
||||||
MasterName: "master",
|
MasterName: "master",
|
||||||
SentinelAddrs: []string{":26379"},
|
SentinelAddrs: []string{":26379"},
|
||||||
})
|
})
|
||||||
|
|
||||||
pong, err := client.Ping().Result()
|
|
||||||
fmt.Println(pong, err)
|
|
||||||
// Output: PONG <nil>
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func ExampleClient() {
|
func ExampleClient() {
|
||||||
|
|
Loading…
Reference in New Issue