Skip to content

Commit

Permalink
Edits
Browse files Browse the repository at this point in the history
  • Loading branch information
grellyd committed Aug 29, 2023
1 parent 0696930 commit 6620791
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion handlers/handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ func QRGen(w http.ResponseWriter, r *http.Request) {
return
}

w.Header().Set("Content-Type", "application/x-www-form-urlencoded")
err = t.Execute(w, nil)
if err != nil {
http.Error(w, fmt.Sprintf("failed to execute '%s' %s\n", string(b), err.Error()), http.StatusInternalServerError)
Expand All @@ -66,7 +67,6 @@ func QRCode(w http.ResponseWriter, r *http.Request) {
http.Error(w, fmt.Sprintln("Wrong method: Got %s; expected %s", r.Method, http.MethodPost), http.StatusBadRequest)
return
}
r.Header.Set("Content-Type", "application/x-www-form-urlencoded")
globallogger.Info("in qrcode")
fmt.Printf("r.RequestURI: %v\n", r.RequestURI)
defer r.Body.Close()
Expand Down

0 comments on commit 6620791

Please sign in to comment.