mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
Update backend/src/graphql/resolver/UserResolver.ts
Co-authored-by: Ulf Gebhardt <ulf.gebhardt@webcraft-media.de>
This commit is contained in:
parent
5e25e5c8eb
commit
506df5268a
@ -193,9 +193,7 @@ const getOptInCode = async (loginUserId: number): Promise<LoginEmailOptIn> => {
|
||||
const timeElapsed = Date.now() - new Date(optInCode.updatedAt).getTime()
|
||||
if (timeElapsed < parseInt(CONFIG.EMAIL_CODE_VALID_TIME.toString()) * 60 * 1000) {
|
||||
throw new Error(
|
||||
'email already sent less than ' +
|
||||
parseInt(CONFIG.EMAIL_CODE_VALID_TIME.toString()) +
|
||||
' minutes ago',
|
||||
`email already sent less than $(CONFIG.EMAIL_CODE_VALID_TIME} minutes ago`
|
||||
)
|
||||
} else {
|
||||
optInCode.updatedAt = new Date()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user