Set http status after modifying response headers.

This commit is contained in:
Chris Lu
2015-01-08 00:19:32 -08:00
parent 31979d6192
commit 5b5d6341e5
10 changed files with 87 additions and 88 deletions

View File

@@ -60,5 +60,5 @@ func (s *RaftServer) statusHandler(w http.ResponseWriter, r *http.Request) {
if leader, e := s.topo.Leader(); e == nil {
ret.Leader = leader
}
writeJsonQuiet(w, r, ret)
writeJsonQuiet(w, r, http.StatusOK, ret)
}