Compare commits

2 Commits
galt ... main

Author SHA1 Message Date
e065799edc Jwt token expiration time extended from 2 to 24h
All checks were successful
Build Feedmee Go Backend App / build-and-push (push) Successful in 1m34s
Build Feedmee Next.js Frontend App / build-and-push (push) Successful in 2m27s
2025-10-29 12:44:50 +01:00
d4452bb3b1 Merge pull request 'galt' (#1) from galt into main
All checks were successful
Build Feedmee Go Backend App / build-and-push (push) Successful in 14s
Build Feedmee Next.js Frontend App / build-and-push (push) Successful in 13s
Reviewed-on: #1
2025-10-20 08:06:40 +02:00

View File

@@ -14,7 +14,7 @@ func generateToken(userID int, username string) (string, error) {
claims := jwt.MapClaims{ claims := jwt.MapClaims{
"user_id": userID, "user_id": userID,
"username": username, "username": username,
"exp": time.Now().Add(2 * time.Hour).Unix(), "exp": time.Now().Add(24 * time.Hour).Unix(),
} }
token := jwt.NewWithClaims(jwt.SigningMethodHS256, claims) token := jwt.NewWithClaims(jwt.SigningMethodHS256, claims)
return token.SignedString(jwtSecret) return token.SignedString(jwtSecret)