mirror of https://github.com/go-redis/redis.git
Remove unnecessary error check
This commit is contained in:
parent
d040650021
commit
e6eeeda3d8
|
@ -359,9 +359,7 @@ func (c *clusterNodes) GetOrCreate(addr string) (*clusterNode, error) {
|
||||||
node = newClusterNode(c.opt, addr)
|
node = newClusterNode(c.opt, addr)
|
||||||
|
|
||||||
c.allAddrs = appendIfNotExists(c.allAddrs, addr)
|
c.allAddrs = appendIfNotExists(c.allAddrs, addr)
|
||||||
if err == nil {
|
c.clusterAddrs = append(c.clusterAddrs, addr)
|
||||||
c.clusterAddrs = append(c.clusterAddrs, addr)
|
|
||||||
}
|
|
||||||
c.allNodes[addr] = node
|
c.allNodes[addr] = node
|
||||||
|
|
||||||
return node, err
|
return node, err
|
||||||
|
|
Loading…
Reference in New Issue