identity-vault/app/mailers/two_factor_mailer.rb
nora 87bb6d4a18
Switch mailers to SES (#72)
* add premailer

* first pass at converting existing mailers

* this EIN is not yours :-P

* remove some css that probably won't work

* that was gonna bug me

* more mailers!

* s/account/auth

* rework 2fa/security mailers

* env vars for SES creds

* add OpenSSL explicitly

* use external logo image

* nuke step_up_code
2025-12-04 16:32:32 -05:00

49 lines
1.1 KiB
Ruby

class TwoFactorMailer < ApplicationMailer
def authentication_method_enabled(identity)
@identity = identity
@first_name = identity.first_name
@env_prefix = env_prefix
mail(
to: identity.primary_email,
from: ACCOUNT_FROM,
subject: prefixed_subject(t(".subject"))
)
end
def authentication_method_disabled(identity)
@identity = identity
@first_name = identity.first_name
@env_prefix = env_prefix
mail(
to: identity.primary_email,
from: ACCOUNT_FROM,
subject: prefixed_subject(t(".subject"))
)
end
def required_authentication_enabled(identity)
@identity = identity
@first_name = identity.first_name
@env_prefix = env_prefix
mail(
to: identity.primary_email,
from: ACCOUNT_FROM,
subject: prefixed_subject(t(".subject"))
)
end
def required_authentication_disabled(identity)
@identity = identity
@first_name = identity.first_name
@env_prefix = env_prefix
mail(
to: identity.primary_email,
from: ACCOUNT_FROM,
subject: prefixed_subject(t(".subject"))
)
end
end