mirror of
https://github.com/redis/go-redis.git
synced 2025-07-28 06:42:00 +03:00
Better rate limited message.
This commit is contained in:
7
redis.go
7
redis.go
@ -20,10 +20,9 @@ func (c *baseClient) conn() (*conn, bool, error) {
|
||||
return c.connPool.Get()
|
||||
}
|
||||
|
||||
func (c *baseClient) putConn(cn *conn, ei error) {
|
||||
var err error
|
||||
if isBadConn(cn, ei) {
|
||||
err = c.connPool.Remove(cn)
|
||||
func (c *baseClient) putConn(cn *conn, err error) {
|
||||
if isBadConn(cn, err) {
|
||||
err = c.connPool.Remove(cn, err)
|
||||
} else {
|
||||
err = c.connPool.Put(cn)
|
||||
}
|
||||
|
Reference in New Issue
Block a user