This commit is contained in:
Henrique Dias
2016-11-01 15:00:36 +00:00
parent 11b37114dc
commit d8d7502b1c
6 changed files with 145 additions and 26 deletions

View File

@@ -139,7 +139,7 @@ func (p Page) PrintAsHTML(w http.ResponseWriter, templates ...string) (int, erro
// PrintAsJSON prints the current Page infromation in JSON
func (p Page) PrintAsJSON(w http.ResponseWriter) (int, error) {
marsh, err := json.Marshal(p.Info.Data)
marsh, err := json.MarshalIndent(p.Info.Data, "", " ")
if err != nil {
return http.StatusInternalServerError, err
}