update
This commit is contained in:
parent
c8eedf5a8f
commit
cbc6405a3e
@ -60,7 +60,7 @@ func GetUserInfo(redisClient *redis.Storage) fiber.Handler {
|
|||||||
var result map[string]interface{}
|
var result map[string]interface{}
|
||||||
json.Unmarshal(body, &result)
|
json.Unmarshal(body, &result)
|
||||||
fmt.Println(result)
|
fmt.Println(result)
|
||||||
if _, ok := result["code"]; !ok || result["code"] != 1 {
|
if _, ok := result["code"]; !ok || int(result["code"].(float64)) != 1 {
|
||||||
return c.Status(http.StatusUnauthorized).JSON(fiber.Map{
|
return c.Status(http.StatusUnauthorized).JSON(fiber.Map{
|
||||||
"message": "获取学生信息失败,身份证无效",
|
"message": "获取学生信息失败,身份证无效",
|
||||||
"error": "身份证无效",
|
"error": "身份证无效",
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user