mirror of
https://github.com/matrix-org/dendrite.git
synced 2026-01-01 03:03:10 -06:00
Whoops, return the value of httputil.UnmarshalJSON
This commit is contained in:
parent
de9f68f60f
commit
022071e17e
|
|
@ -551,10 +551,7 @@ func Register(
|
|||
r.InhibitLogin = data.InhibitLogin
|
||||
}
|
||||
if resErr := httputil.UnmarshalJSON(reqBody, &r); resErr != nil {
|
||||
return util.JSONResponse{
|
||||
Code: http.StatusBadRequest,
|
||||
JSON: jsonerror.BadJSON("Request body contains invalid JSON"),
|
||||
}
|
||||
return *resErr
|
||||
}
|
||||
if req.URL.Query().Get("kind") == "guest" {
|
||||
return handleGuestRegistration(req, r, cfg, userAPI)
|
||||
|
|
|
|||
Loading…
Reference in a new issue