diff options
Diffstat (limited to 'server/lib/emailer.ts')
-rw-r--r-- | server/lib/emailer.ts | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/server/lib/emailer.ts b/server/lib/emailer.ts index c08732b48..ee8498c41 100644 --- a/server/lib/emailer.ts +++ b/server/lib/emailer.ts | |||
@@ -387,12 +387,13 @@ class Emailer { | |||
387 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) | 387 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) |
388 | } | 388 | } |
389 | 389 | ||
390 | addPasswordResetEmailJob (to: string, resetPasswordUrl: string) { | 390 | addPasswordResetEmailJob (username: string, to: string, resetPasswordUrl: string) { |
391 | const emailPayload: EmailPayload = { | 391 | const emailPayload: EmailPayload = { |
392 | template: 'password-reset', | 392 | template: 'password-reset', |
393 | to: [ to ], | 393 | to: [ to ], |
394 | subject: 'Reset your account password', | 394 | subject: 'Reset your account password', |
395 | locals: { | 395 | locals: { |
396 | username, | ||
396 | resetPasswordUrl | 397 | resetPasswordUrl |
397 | } | 398 | } |
398 | } | 399 | } |
@@ -414,12 +415,13 @@ class Emailer { | |||
414 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) | 415 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) |
415 | } | 416 | } |
416 | 417 | ||
417 | addVerifyEmailJob (to: string, verifyEmailUrl: string) { | 418 | addVerifyEmailJob (username: string, to: string, verifyEmailUrl: string) { |
418 | const emailPayload: EmailPayload = { | 419 | const emailPayload: EmailPayload = { |
419 | template: 'verify-email', | 420 | template: 'verify-email', |
420 | to: [ to ], | 421 | to: [ to ], |
421 | subject: `Verify your email on ${WEBSERVER.HOST}`, | 422 | subject: `Verify your email on ${WEBSERVER.HOST}`, |
422 | locals: { | 423 | locals: { |
424 | username, | ||
423 | verifyEmailUrl | 425 | verifyEmailUrl |
424 | } | 426 | } |
425 | } | 427 | } |