X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Flib%2Femailer.ts;h=672414cc0c95ac94ca18d5fb64cd3f6621cd6ac4;hb=b426edd4854adc6e65844d8c54b8998e792b5778;hp=7681164b3fc93eb4ddc9f8be4fb2fcdf8c3ddf9a;hpb=67b1d3fed765278bdc876cce393ef56d56942df0;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/lib/emailer.ts b/server/lib/emailer.ts index 7681164b3..672414cc0 100644 --- a/server/lib/emailer.ts +++ b/server/lib/emailer.ts @@ -101,22 +101,6 @@ class Emailer { return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) } - addForceResetPasswordEmailJob (to: string, resetPasswordUrl: string) { - const text = `Hi dear user,\n\n` + - `Your password has been reset on ${CONFIG.WEBSERVER.HOST}! ` + - `Please follow this link to reset it: ${resetPasswordUrl}\n\n` + - `Cheers,\n` + - `PeerTube.` - - const emailPayload: EmailPayload = { - to: [ to ], - subject: 'Reset of your PeerTube password', - text - } - - return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) - } - addNewFollowNotification (to: string[], actorFollow: ActorFollowModel, followType: 'account' | 'channel') { const followerName = actorFollow.ActorFollower.Account.getDisplayName() const followingName = (actorFollow.ActorFollowing.VideoChannel || actorFollow.ActorFollowing.Account).getDisplayName() @@ -312,9 +296,9 @@ class Emailer { return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) } - addForgetPasswordEmailJob (to: string, resetPasswordUrl: string) { + addPasswordResetEmailJob (to: string, resetPasswordUrl: string) { const text = `Hi dear user,\n\n` + - `It seems you forgot your password on ${CONFIG.WEBSERVER.HOST}! ` + + `A reset password procedure for your account ${to} has been requested on ${CONFIG.WEBSERVER.HOST} ` + `Please follow this link to reset it: ${resetPasswordUrl}\n\n` + `If you are not the person who initiated this request, please ignore this email.\n\n` + `Cheers,\n` +