mirror of
https://github.com/hoernschen/dendrite.git
synced 2024-12-27 07:28:27 +00:00
Account for application service headers auth
This commit is contained in:
parent
c091a4bcb3
commit
c594bbddb4
1 changed files with 2 additions and 1 deletions
|
@ -497,7 +497,8 @@ func Register(
|
||||||
// Application services can register users with no auth type, but require
|
// Application services can register users with no auth type, but require
|
||||||
// access token. Differentiate from users who are initially hitting register
|
// access token. Differentiate from users who are initially hitting register
|
||||||
// without an auth type
|
// without an auth type
|
||||||
if r.Auth.Type == "" && req.URL.Query().Get("access_token") == "" {
|
if r.Auth.Type == "" && req.URL.Query().Get("access_token") == "" &&
|
||||||
|
req.Header.Get("Authorization") == "" {
|
||||||
return util.JSONResponse{
|
return util.JSONResponse{
|
||||||
Code: http.StatusUnauthorized,
|
Code: http.StatusUnauthorized,
|
||||||
JSON: newUserInteractiveResponse(sessionID,
|
JSON: newUserInteractiveResponse(sessionID,
|
||||||
|
|
Loading…
Reference in a new issue