From 6c31c050fafe189adc62b2ea7f775edce180f48b Mon Sep 17 00:00:00 2001 From: ZJY <764763903@qq.com> Date: Thu, 16 Sep 2021 16:28:02 +0800 Subject: [PATCH] =?UTF-8?q?fix=20=E6=96=B0=E5=A2=9E=E4=BC=9A=E5=91=98?= =?UTF-8?q?=E4=B8=AD=E5=BF=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- controllers/login.go | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/controllers/login.go b/controllers/login.go index 917c490..428393e 100644 --- a/controllers/login.go +++ b/controllers/login.go @@ -403,17 +403,18 @@ func (c *LoginController) CkLogin() { } } + } else { + result := Result{ + Data: "null", + Code: 2, + Message: "ck格式错误", + } + jsons, errs := json.Marshal(result) //转换成JSON返回的是byte[] + if errs != nil { + fmt.Println(errs.Error()) + } + c.Ctx.WriteString(string(jsons)) } - result := Result{ - Data: "null", - Code: 2, - Message: "ck格式错误", - } - jsons, errs := json.Marshal(result) //转换成JSON返回的是byte[] - if errs != nil { - fmt.Println(errs.Error()) - } - c.Ctx.WriteString(string(jsons)) //if strings.Contains(ck,"pt_key") { // ptKey := FetchJdCookieValue("pt_key", msg)