修复结点删除错误

This commit is contained in:
boyce
2020-12-01 09:48:02 +08:00
parent 0eea4dc446
commit 3d42763b52

View File

@@ -75,7 +75,7 @@ func (cls *Cluster) delServiceNode(serviceName string,nodeId int){
nodeList := cls.mapServiceNode[serviceName]
for idx,nId := range nodeList {
if nId == nodeId {
cls.mapServiceNode[serviceName] = append(nodeList[idx:],nodeList[idx+1:]...)
cls.mapServiceNode[serviceName] = append(nodeList[:idx],nodeList[idx+1:]...)
return
}
}