mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-06 16:27:46 +00:00
Add parseInt to token expiration
This commit is contained in:
@@ -66,7 +66,7 @@ const checkEmailVerification = async ({
|
|||||||
email,
|
email,
|
||||||
token: code
|
token: code
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!token) throw new Error('Failed to find email verification token');
|
if (!token) throw new Error('Failed to find email verification token');
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
Sentry.setUser(null);
|
Sentry.setUser(null);
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ const tokenSchema = new Schema<IToken>({
|
|||||||
},
|
},
|
||||||
createdAt: {
|
createdAt: {
|
||||||
type: Date,
|
type: Date,
|
||||||
expires: EMAIL_TOKEN_LIFETIME,
|
expires: parseInt(EMAIL_TOKEN_LIFETIME),
|
||||||
default: Date.now
|
default: Date.now
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user