微软第三方登录问题

This commit is contained in:
junleea 2025-05-18 11:19:25 +08:00
parent a1d9cc41fc
commit b556379bf6
2 changed files with 2 additions and 1 deletions

View File

@ -892,7 +892,7 @@ func handleThirdPartyCallback(c *gin.Context) {
log.Println("state is empty,stateID=", stateID)
} else {
//json解析
log.Println("stateStr:", stateStr, "\tcode:", code)
//log.Println("stateStr:", stateStr, "\tcode:", code)
var state proto.ThirdPartyLoginState
err := json.Unmarshal([]byte(stateStr), &state)
log.Println("handle callback state:", stateStr, "\tcode:", code)

View File

@ -595,6 +595,7 @@ func GetMicroSoftAccessTokenByCode(code string, redirectURI string, clientID str
log.Println("microsoft response err:", err2)
return resp, err2
}
log.Println("microsoft response content:", string(respBytes))
err = json.Unmarshal(respBytes, &resp)
if err != nil {
log.Println("microsoft response decode err:", err, " response content:", string(respBytes))