mirror of
https://github.com/redis/go-redis.git
synced 2025-07-29 17:41:15 +03:00
Simplify internal API
This commit is contained in:
10
pipeline.go
10
pipeline.go
@ -67,13 +67,9 @@ func (c *Pipeline) Exec() ([]Cmder, error) {
|
||||
return cmds, err
|
||||
}
|
||||
|
||||
if err := c.execCmds(cn, cmds); err != nil {
|
||||
c.client.freeConn(cn, err)
|
||||
return cmds, err
|
||||
}
|
||||
|
||||
c.client.putConn(cn)
|
||||
return cmds, nil
|
||||
err = c.execCmds(cn, cmds)
|
||||
c.client.putConn(cn, err)
|
||||
return cmds, err
|
||||
}
|
||||
|
||||
func (c *Pipeline) execCmds(cn *conn, cmds []Cmder) error {
|
||||
|
Reference in New Issue
Block a user