fixed api bug where empty fields weren't being omitted

This commit is contained in:
cdramey authored and Christopher Ramey committed 2019-12-26 16:25:16 -09:00
1 parent f6d59bcdd8
commit d272cafd2e
2 files changed
+4 -3

No files matched your search

+3 -3
View File
@@ -11,9 +11,9 @@ import (
)
type apijson struct {
URL string `json:"url",omitempty`
Exists bool `json:"exists",omitempty`
Error string `json:"error",omitempty`
URL string `json:"url,omitempty"`
Exists bool `json:"exists,omitempty"`
Error string `json:"error,omitempty"`
}
func (ctx *RootHandler) ServeAPI(w http.ResponseWriter, r *http.Request) {