mirror of
https://gitee.com/mirrors/AllinSSL.git
synced 2026-03-26 07:24:32 +08:00
修复验证码cookie
This commit is contained in:
@@ -99,7 +99,7 @@ func Sign(c *gin.Context) {
|
||||
_ = session.Save()
|
||||
// c.JSON(http.StatusBadRequest, public.ResERR("用户不存在"))
|
||||
// 设置cookie
|
||||
c.SetCookie("must_code", "1", 0, "/", "", false, true)
|
||||
c.SetCookie("must_code", "1", 0, "/", "", false, false)
|
||||
public.FailMsg(c, "用户不存在")
|
||||
return
|
||||
}
|
||||
@@ -137,7 +137,7 @@ func Sign(c *gin.Context) {
|
||||
_ = session.Save()
|
||||
// c.JSON(http.StatusOK, public.ResOK(0, nil, "登录成功"))
|
||||
// 设置cookie
|
||||
c.SetCookie("must_code", "1", -1, "/", "", false, true)
|
||||
c.SetCookie("must_code", "1", 0, "/", "", false, false)
|
||||
public.SuccessMsg(c, "登录成功")
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user