mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FEATURE: send set password instructions after invite redemption
This commit is contained in:
@@ -42,4 +42,13 @@ class InviteMailer < ActionMailer::Base
|
||||
|
||||
end
|
||||
|
||||
def send_password_instructions(user)
|
||||
if user.present?
|
||||
email_token = user.email_tokens.create(email: user.email)
|
||||
build_email(user.email,
|
||||
template: 'invite_password_instructions',
|
||||
email_token: email_token.token)
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user