diff --git a/internal/handlers/handlers.go b/internal/handlers/handlers.go index 9c5e7f7..6eb917d 100644 --- a/internal/handlers/handlers.go +++ b/internal/handlers/handlers.go @@ -83,6 +83,7 @@ func (h *RadioHandlers) Stats(w http.ResponseWriter, _ *http.Request) { return } + w.Header().Add("Content-Type", "application/json") json.NewEncoder(w).Encode(status) } @@ -96,6 +97,8 @@ func (h *RadioHandlers) LastSong(w http.ResponseWriter, _ *http.Request) { w.WriteHeader(http.StatusNotFound) return } + + w.Header().Add("Content-Type", "application/json") json.NewEncoder(w).Encode(songs[0]) }