Skip to content

Commit

Permalink
fix: Add a lead time for the token's issuance time. (#2914)
Browse files Browse the repository at this point in the history
  • Loading branch information
icey-yu authored Dec 13, 2024
1 parent b802437 commit 7563aff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/rpc/auth/auth.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ func (s *authServer) GetUserToken(ctx context.Context, req *pbauth.GetUserTokenR
func (s *authServer) parseToken(ctx context.Context, tokensString string) (claims *tokenverify.Claims, err error) {
claims, err = tokenverify.GetClaimFromToken(tokensString, authverify.Secret(s.config.Share.Secret))
if err != nil {
return nil, errs.Wrap(err)
return nil, err
}
isAdmin := authverify.IsManagerUserID(claims.UserID, s.config.Share.IMAdminUserID)
if isAdmin {
Expand Down

0 comments on commit 7563aff

Please sign in to comment.