Always show self in cluster list (fixes #43)
This commit is contained in:
parent
e6078f9449
commit
13854250b3
1
gui.go
1
gui.go
@ -84,6 +84,7 @@ func restGetConfig(w http.ResponseWriter) {
|
|||||||
res["myID"] = myID
|
res["myID"] = myID
|
||||||
res["repository"] = config.OptionMap("repository")
|
res["repository"] = config.OptionMap("repository")
|
||||||
res["nodes"] = config.OptionMap("nodes")
|
res["nodes"] = config.OptionMap("nodes")
|
||||||
|
res["nodes"].(map[string]string)[myID] = "self"
|
||||||
w.Header().Set("Content-Type", "application/json")
|
w.Header().Set("Content-Type", "application/json")
|
||||||
json.NewEncoder(w).Encode(res)
|
json.NewEncoder(w).Encode(res)
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user