1
0
Fork 0

Add charset

This commit is contained in:
Gregory Eremin 2014-09-25 17:23:59 +04:00
parent ee34e14320
commit 5f1ed72712
1 changed files with 3 additions and 3 deletions

View File

@ -48,7 +48,7 @@ func (s *Server) statusHandler(w http.ResponseWriter, r *http.Request) {
info := s.hub.Info()
jsn, _ := json.Marshal(info)
w.Header().Set("Content-Type", "application/json")
w.Header().Set("Content-Type", "application/json; charset=utf-8")
w.Write(jsn)
}
@ -60,7 +60,7 @@ func (s *Server) debugHandler(w http.ResponseWriter, r *http.Request) {
info["kyoto_cabinet"] = s.hub.StorageInfo()
jsn, _ := json.Marshal(info)
w.Header().Set("Content-Type", "application/json")
w.Header().Set("Content-Type", "application/json; charset=utf-8")
w.Write(jsn)
}
@ -107,6 +107,6 @@ func (s *Server) flushHandler(w http.ResponseWriter, r *http.Request) {
messages := s.hub.Flush(queues)
jsn, _ := json.Marshal(messages)
w.Header().Set("Content-Type", "application/json")
w.Header().Set("Content-Type", "application/json; charset=utf-8")
w.Write(jsn)
}