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 d54eab966..48ba7421e 100644 --- a/server/lib/emailer.ts +++ b/server/lib/emailer.ts | |||
@@ -427,12 +427,13 @@ class Emailer { | |||
427 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) | 427 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) |
428 | } | 428 | } |
429 | 429 | ||
430 | addPasswordResetEmailJob (to: string, resetPasswordUrl: string) { | 430 | addPasswordResetEmailJob (username: string, to: string, resetPasswordUrl: string) { |
431 | const emailPayload: EmailPayload = { | 431 | const emailPayload: EmailPayload = { |
432 | template: 'password-reset', | 432 | template: 'password-reset', |
433 | to: [ to ], | 433 | to: [ to ], |
434 | subject: 'Reset your account password', | 434 | subject: 'Reset your account password', |
435 | locals: { | 435 | locals: { |
436 | username, | ||
436 | resetPasswordUrl | 437 | resetPasswordUrl |
437 | } | 438 | } |
438 | } | 439 | } |
@@ -454,12 +455,13 @@ class Emailer { | |||
454 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) | 455 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) |
455 | } | 456 | } |
456 | 457 | ||
457 | addVerifyEmailJob (to: string, verifyEmailUrl: string) { | 458 | addVerifyEmailJob (username: string, to: string, verifyEmailUrl: string) { |
458 | const emailPayload: EmailPayload = { | 459 | const emailPayload: EmailPayload = { |
459 | template: 'verify-email', | 460 | template: 'verify-email', |
460 | to: [ to ], | 461 | to: [ to ], |
461 | subject: `Verify your email on ${WEBSERVER.HOST}`, | 462 | subject: `Verify your email on ${WEBSERVER.HOST}`, |
462 | locals: { | 463 | locals: { |
464 | username, | ||
463 | verifyEmailUrl | 465 | verifyEmailUrl |
464 | } | 466 | } |
465 | } | 467 | } |