fix: 问题修复

This commit is contained in:
meilin.huang
2024-05-16 17:26:32 +08:00
parent 89e12678eb
commit c4cb4234fd
46 changed files with 416 additions and 262 deletions

View File

@@ -123,9 +123,8 @@ func (a *AccountLogin) RefreshToken(rc *req.Ctx) {
biz.NotEmpty(refreshToken, "refresh_token不能为空")
accountId, username, err := req.ParseToken(refreshToken)
if err != nil {
panic(errorx.PermissionErr)
}
biz.IsTrueBy(err == nil, errorx.PermissionErr)
token, refreshToken, err := req.CreateToken(accountId, username)
biz.ErrIsNil(err)
rc.ResData = collx.Kvs("token", token, "refresh_token", refreshToken)