From ebbeb40416e82629df1ff0c0353de367685a043f Mon Sep 17 00:00:00 2001 From: Vladimir Mihailenco Date: Wed, 6 Apr 2016 13:19:00 +0300 Subject: [PATCH] Disable logging by default. --- redis.go | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/redis.go b/redis.go index 10d5092..aed713c 100644 --- a/redis.go +++ b/redis.go @@ -2,18 +2,14 @@ package redis // import "gopkg.in/redis.v3" import ( "fmt" + "io/ioutil" "log" - "os" "gopkg.in/redis.v3/internal/pool" ) // Deprecated. Use SetLogger instead. -var Logger *log.Logger - -func init() { - SetLogger(log.New(os.Stderr, "redis: ", log.LstdFlags)) -} +var Logger = log.New(ioutil.Discard, "redis: ", log.LstdFlags) func SetLogger(logger *log.Logger) { Logger = logger