fix(api): set Content-Type response header
This commit is contained in:
parent
4e12f0f7d4
commit
503aedbf37
1 changed files with 1 additions and 0 deletions
|
@ -129,6 +129,7 @@ func generateJSON(ip string) (body, error) {
|
|||
|
||||
func handleRequest(w http.ResponseWriter, r *http.Request) {
|
||||
w.Header().Add("Access-Control-Allow-Origin", "*")
|
||||
w.Header().Add("Content-Type", "application/json")
|
||||
|
||||
sourceIP := func() string {
|
||||
if q := r.URL.Query().Get("q"); q != "" {
|
||||
|
|
Loading…
Reference in a new issue