Skip to content

Commit

Permalink
still no one saw anything
Browse files Browse the repository at this point in the history
  • Loading branch information
harshkhandeparkar committed Dec 16, 2023
1 parent 672b021 commit 0e77a0d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions utils/jwt.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ func ParseLoginJwtString(tokenString string) (*jwt.Token, *LoginJwtClaims, error
var loginClaims = LoginJwtClaims{}
token, err := jwt.ParseWithClaims(tokenString, &loginClaims, jwtKeyFunc)

if err.Error() == fmt.Sprintf("%s: %s", jwt.ErrTokenInvalidClaims.Error(), jwt.ErrTokenExpired.Error()) {
return nil, nil, ErrJwtTokenExpired
}

if err != nil {
if err.Error() == fmt.Sprintf("%s: %s", jwt.ErrTokenInvalidClaims.Error(), jwt.ErrTokenExpired.Error()) {
return nil, nil, ErrJwtTokenExpired
}

return nil, nil, err
}

Expand Down

0 comments on commit 0e77a0d

Please sign in to comment.