extend the token lifetime

This commit is contained in:
Chris Cromer 2023-01-28 20:59:53 -03:00
parent 49dbe22df7
commit 971d4a28f5
Signed by: cromer
GPG Key ID: FA91071797BEEEC2

View File

@ -15,7 +15,7 @@ type JWTClaim struct {
} }
func GenerateJWT(email string, username string) (tokenString string, err error) { func GenerateJWT(email string, username string) (tokenString string, err error) {
expirationTime := time.Now().Add(1 * time.Hour) expirationTime := time.Now().Add(24 * time.Hour)
claims := &JWTClaim{ claims := &JWTClaim{
Email: email, Email: email,
Username: username, Username: username,