diff --git a/switch.go b/switch.go index 2aa12ec..130c3b5 100644 --- a/switch.go +++ b/switch.go @@ -200,7 +200,6 @@ func (swi *Switch) switchActives(w http.ResponseWriter, req *http.Request) { for addr, group := range swi.Worker.ForLoop { addrmap := make(map[string]interface{}) - content[addr] = addrmap isappend := int64(0) var hosts []string @@ -211,6 +210,7 @@ func (swi *Switch) switchActives(w http.ResponseWriter, req *http.Request) { hosts = append(hosts, dhost.Host) } if isappend > 1 { + content[addr] = addrmap addrmap["group"] = hosts addrmap["city"] = group.City }