1
0
mirror of https://github.com/redis/go-redis.git synced 2025-07-28 06:42:00 +03:00

Support default redis address

This commit is contained in:
mingrammer
2019-01-13 17:36:38 +09:00
parent d9c8076236
commit c9fed25a60
2 changed files with 6 additions and 3 deletions

View File

@ -24,9 +24,9 @@ func init() {
func ExampleNewClient() {
redisdb := redis.NewClient(&redis.Options{
Addr: "localhost:6379",
Password: "", // no password set
DB: 0, // use default DB
Addr: "localhost:6379", // use default Addr
Password: "", // no password set
DB: 0, // use default DB
})
pong, err := redisdb.Ping().Result()