add service
All checks were successful
Deploy Smart Search Gateway Test / deploy (push) Successful in 2m2s

This commit is contained in:
vallyenfail
2026-01-20 00:00:54 +03:00
parent c8305144a1
commit afcf20f43a
2 changed files with 1 additions and 2 deletions

View File

@@ -28,7 +28,7 @@ func Auth(jwtSecret string) fiber.Handler {
return errors.RespondWithError(c, errors.CodeAuthInvalidToken, "Invalid token type", nil)
}
userID, err := strconv.ParseInt(claims.Sub, 10, 64)
userID, err := strconv.ParseInt(claims.Subject, 10, 64)
if err != nil {
return errors.RespondWithError(c, errors.CodeAuthInvalidToken, "Invalid user ID in token", err)
}

View File

@@ -7,7 +7,6 @@ import (
)
type Claims struct {
Sub string `json:"sub"`
Type string `json:"type"`
jwt.RegisteredClaims
}