mirror of
https://github.com/mayswind/ezbookkeeping.git
synced 2026-05-14 06:57:35 +08:00
redirect to login page when user logout without token
This commit is contained in:
@@ -100,6 +100,10 @@ func (s *TokenService) ParseToken(c *core.Context) (*jwt.Token, *core.UserTokenC
|
||||
}, request.WithClaims(claims))
|
||||
|
||||
if err != nil {
|
||||
if err == request.ErrNoTokenInRequest {
|
||||
return nil, nil, errs.ErrTokenIsEmpty
|
||||
}
|
||||
|
||||
return nil, nil, err
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user