mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 10:49:28 +02:00
Fix: display username in password-reset and verify-email notifs
This commit is contained in:
parent
0bdad52fbb
commit
963023abe6
4 changed files with 10 additions and 7 deletions
|
@ -387,12 +387,13 @@ class Emailer {
|
|||
return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload })
|
||||
}
|
||||
|
||||
addPasswordResetEmailJob (to: string, resetPasswordUrl: string) {
|
||||
addPasswordResetEmailJob (username: string, to: string, resetPasswordUrl: string) {
|
||||
const emailPayload: EmailPayload = {
|
||||
template: 'password-reset',
|
||||
to: [ to ],
|
||||
subject: 'Reset your account password',
|
||||
locals: {
|
||||
username,
|
||||
resetPasswordUrl
|
||||
}
|
||||
}
|
||||
|
@ -414,12 +415,13 @@ class Emailer {
|
|||
return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload })
|
||||
}
|
||||
|
||||
addVerifyEmailJob (to: string, verifyEmailUrl: string) {
|
||||
addVerifyEmailJob (username: string, to: string, verifyEmailUrl: string) {
|
||||
const emailPayload: EmailPayload = {
|
||||
template: 'verify-email',
|
||||
to: [ to ],
|
||||
subject: `Verify your email on ${WEBSERVER.HOST}`,
|
||||
locals: {
|
||||
username,
|
||||
verifyEmailUrl
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue