fixed api bug where empty fields weren't being omitted
This commit is contained in:
parent
f6d59bcdd8
commit
d272cafd2e
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,2 +1,3 @@
|
||||
*.swp
|
||||
qurl
|
||||
qurl.db
|
||||
|
@ -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) {
|
||||
|
Loading…
Reference in New Issue
Block a user