Skip to content

Commit 8e655bc

Browse files
committed
fix: authorize response
1 parent 9a411e6 commit 8e655bc

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

server/handlers/authorize.go

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -152,16 +152,16 @@ func AuthorizeHandler() gin.HandlerFunc {
152152

153153
// in case, response type is code and user is already logged in send the code and state
154154
// and cookie session will already be rolled over and set
155-
gc.HTML(http.StatusOK, authorizeWebMessageTemplate, gin.H{
156-
"target_origin": redirectURI,
157-
"authorization_response": map[string]interface{}{
158-
"type": "authorization_response",
159-
"response": map[string]string{
160-
"code": code,
161-
"state": state,
162-
},
163-
},
164-
})
155+
// gc.HTML(http.StatusOK, authorizeWebMessageTemplate, gin.H{
156+
// "target_origin": redirectURI,
157+
// "authorization_response": map[string]interface{}{
158+
// "type": "authorization_response",
159+
// "response": map[string]string{
160+
// "code": code,
161+
// "state": state,
162+
// },
163+
// },
164+
// })
165165

166166
// params := "code=" + code + "&state=" + state
167167

@@ -179,10 +179,10 @@ func AuthorizeHandler() gin.HandlerFunc {
179179
// }
180180
// }
181181

182-
// handleResponse(gc, responseMode, loginURL, redirectURI, map[string]interface{}{
183-
// "code": code,
184-
// "state": state,
185-
// }, http.StatusOK)
182+
handleResponse(gc, responseMode, loginURL, redirectURI, map[string]interface{}{
183+
"code": code,
184+
"state": state,
185+
}, http.StatusOK)
186186

187187
return
188188
}

0 commit comments

Comments
 (0)