Commit 165f29ad by CalciumIon

fix bug

parent aad24769
...@@ -146,7 +146,7 @@ func TokenAuth() func(c *gin.Context) { ...@@ -146,7 +146,7 @@ func TokenAuth() func(c *gin.Context) {
if token != nil { if token != nil {
id := c.GetInt("id") id := c.GetInt("id")
if id == 0 { if id == 0 {
c.Set("id", token.Id) c.Set("id", token.UserId)
} }
} }
if err != nil { if err != nil {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment