diff --git a/business/auth2/auth2.go b/business/auth2/auth2.go index b61df8e14..0f9a077c7 100644 --- a/business/auth2/auth2.go +++ b/business/auth2/auth2.go @@ -351,12 +351,12 @@ func RemoveUserInfo(token string) { func GetTokenInfo(token string) (authInfo *AuthInfo, err error) { if authInfo = getFixedTokenName(token); authInfo != nil { - if authInfo.Mobile == "" { - authInfo.TokenType = 2 - } return authInfo, nil } if err = api.Cacher.GetAs(token, &authInfo); err == nil { + if authInfo.Mobile == "" { + authInfo.TokenType = 2 + } return authInfo, nil } return nil, model.ErrTokenIsInvalid