Added valid until text to invite email (#2599)

This commit is contained in:
Ahmad Farhat
2021-03-22 19:26:51 -04:00
committed by GitHub
parent c21dd8f39a
commit 79beb7f3fa
7 changed files with 17 additions and 9 deletions

View File

@ -70,11 +70,11 @@ module Emailer
end
# Sends inivitation to join
def send_invitation_email(name, email, token)
def send_invitation_email(name, email, invite)
begin
return unless Rails.configuration.enable_email_verification
UserMailer.invite_email(name, email, invitation_link(token), @settings).deliver_now
UserMailer.invite_email(name, email, invite.updated_at, invitation_link(invite.invite_token), @settings).deliver_now
rescue => e
logger.error "Support: Error in email delivery: #{e}"
flash[:alert] = I18n.t(params[:message], default: I18n.t("delivery_error"))