mirror of
https://github.com/davidallendj/opaal.git
synced 2026-06-03 08:31:52 -06:00
Ensure Content-Type is set to application/json
Signed-off-by: Chris Harris <cjh@lbl.gov>
This commit is contained in:
parent
581aca14b8
commit
93a1fea300
1 changed files with 2 additions and 0 deletions
|
|
@ -183,6 +183,7 @@ func (s *Server) StartLogin(clients []oauth.Client, params ServerParams) error {
|
|||
return
|
||||
}
|
||||
|
||||
w.Header().Set("Content-Type", "application/json")
|
||||
w.Write(jwks)
|
||||
})
|
||||
r.HandleFunc("/token", func(w http.ResponseWriter, r *http.Request) {
|
||||
|
|
@ -218,6 +219,7 @@ func (s *Server) StartLogin(clients []oauth.Client, params ServerParams) error {
|
|||
http.Redirect(w, r, "/error", http.StatusInternalServerError)
|
||||
return
|
||||
}
|
||||
w.Header().Set("Content-Type", "application/json")
|
||||
w.Write([]byte(accessToken))
|
||||
}
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue