mirror of
https://github.com/redis/go-redis.git
synced 2025-07-28 06:42:00 +03:00
Add ErrTxFailed. Small tweaks.
This commit is contained in:
@ -73,7 +73,7 @@ func (c *baseClient) init(cn *conn, password string, db int64) error {
|
||||
}
|
||||
|
||||
func (c *baseClient) freeConn(cn *conn, err error) {
|
||||
if err == Nil {
|
||||
if err == Nil || err == TxFailedErr {
|
||||
c.putConn(cn)
|
||||
} else {
|
||||
c.removeConn(cn)
|
||||
|
Reference in New Issue
Block a user