This commit is contained in:
parent
fd345d6b21
commit
67f42dad43
|
|
@ -34,14 +34,7 @@ func WechatAuth(c *gin.Context) {
|
|||
})
|
||||
return
|
||||
}
|
||||
code := c.Query("code")
|
||||
if code == "" {
|
||||
c.JSON(http.StatusBadRequest, gin.H{
|
||||
"error": "code is required",
|
||||
})
|
||||
return
|
||||
}
|
||||
resp, err := service.WechatAuth(&reqid, &code)
|
||||
resp, err := service.WechatAuth(&reqid)
|
||||
if err != nil {
|
||||
c.JSON(http.StatusInternalServerError, gin.H{
|
||||
"error": err.Error(),
|
||||
|
|
|
|||
Loading…
Reference in New Issue