Skip to content

Commit

Permalink
Update MAP_VALIDATION.md (#61)
Browse files Browse the repository at this point in the history
* Added `ValidateStruct` to validate a struct without a request (#57) (#58)

Fixes #12

* Update MAP_VALIDATION.md

Fixed typo
  • Loading branch information
tiagoacardoso authored and thedevsaddam committed Jun 14, 2019
1 parent 0413a0e commit 12641b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/MAP_VALIDATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func handler(w http.ResponseWriter, r *http.Request) {
e := vd.ValidateJSON()
fmt.Println(data)
err := map[string]interface{}{"validation error": e}
w.Header().Set("Content-type", "applciation/json")
w.Header().Set("Content-type", "application/json")
json.NewEncoder(w).Encode(err)
}

Expand Down

0 comments on commit 12641b3

Please sign in to comment.