mirror of
https://github.com/TeaOSLab/EdgeAPI.git
synced 2025-11-07 10:40:25 +08:00
修复同属多集群下的节点无法删除线路的Bug
This commit is contained in:
@@ -1328,6 +1328,7 @@ func (this *NodeService) UpdateNodeDNS(ctx context.Context, req *pb.UpdateNodeDN
|
||||
delete(routeCodeMap, req.DnsDomainId)
|
||||
}
|
||||
} else {
|
||||
routeCodeMap = map[int64][]string{}
|
||||
if len(req.Routes) > 0 {
|
||||
var m = map[int64][]string{} // domainId => codes
|
||||
for _, route := range req.Routes {
|
||||
@@ -1342,9 +1343,6 @@ func (this *NodeService) UpdateNodeDNS(ctx context.Context, req *pb.UpdateNodeDN
|
||||
for domainId, codes := range m {
|
||||
routeCodeMap[domainId] = codes
|
||||
}
|
||||
} else {
|
||||
// 清空
|
||||
routeCodeMap = map[int64][]string{}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user