From 143581879253fae94fa3b409f6736dda3a115469 Mon Sep 17 00:00:00 2001 From: Thordur Bjornsson Date: Thu, 1 Jan 2015 15:33:33 +0100 Subject: [PATCH] handle ?pretty similarly to ?stale, ?consistent etc. --- command/agent/http.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/command/agent/http.go b/command/agent/http.go index 8c174711bf..365db74c87 100644 --- a/command/agent/http.go +++ b/command/agent/http.go @@ -253,7 +253,7 @@ func (s *HTTPServer) wrap(handler func(resp http.ResponseWriter, req *http.Reque } prettyPrint := false - if req.URL.Query().Get("pretty") != "" { + if _, ok := req.URL.Query()["pretty"]; ok { prettyPrint = true } // Write out the JSON object