修复获取第三方绑定Url问题
This commit is contained in:
parent
ba553984e4
commit
13e115f2e0
|
|
@ -723,15 +723,20 @@ func GetThirdPartyAuthUrl(c *gin.Context) {
|
|||
if hType == "add" {
|
||||
//查看是否已经绑定
|
||||
token := c.Request.Header.Get("token")
|
||||
if token == "" {
|
||||
token = c.Query("token")
|
||||
}
|
||||
if token == "" {
|
||||
resp.Code = proto.ParameterError
|
||||
resp.Message = "token is empty"
|
||||
c.JSON(http.StatusOK, resp)
|
||||
return
|
||||
}
|
||||
userID, err := service.DecodeJWTToken(token)
|
||||
if err != nil {
|
||||
resp.Code = proto.ParameterError
|
||||
resp.Message = err.Error()
|
||||
c.JSON(http.StatusOK, resp)
|
||||
return
|
||||
}
|
||||
//需要将uuid绑定在该用户上
|
||||
|
|
|
|||
Loading…
Reference in New Issue