fix record usage

This commit is contained in:
Sakurasan
2025-04-22 00:48:24 +08:00
parent 5789d50e9e
commit 6662ea5e04
4 changed files with 89 additions and 46 deletions

View File

@@ -95,6 +95,7 @@ func AuthLLM(db *gorm.DB) gin.HandlerFunc {
c.Set("user", token.User)
c.Set("user_id", token.User.ID)
c.Set("token_id", token.ID)
c.Set("authed", true)
// 可以在这里对 token 进行验证并检查权限