Skip to content

Commit

Permalink
Remove unused mailers (#1975)
Browse files Browse the repository at this point in the history
* Remove unused mailers

* Delete file
  • Loading branch information
Cory McDonald authored Jun 19, 2019
1 parent fdce479 commit 43c0374
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 46 deletions.
17 changes: 0 additions & 17 deletions app/mailers/publisher_mailer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -121,14 +121,6 @@ def notify_email_change(publisher)
)
end

def uphold_account_changed(publisher)
@publisher = publisher
mail(
to: @publisher.email,
subject: default_i18n_subject
)
end

def uphold_kyc_incomplete(publisher)
@publisher = publisher
mail(
Expand All @@ -145,15 +137,6 @@ def uphold_member_restricted(publisher)
)
end

def statement_ready(publisher_statement)
@publisher_statement = publisher_statement
@publisher = publisher_statement.publisher
mail(
to: @publisher.email,
subject: default_i18n_subject
)
end

def suspend_publisher(publisher)
@publisher = publisher
mail(
Expand Down
9 changes: 0 additions & 9 deletions app/views/publisher_mailer/uphold_account_changed.html.slim

This file was deleted.

4 changes: 0 additions & 4 deletions config/locales/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -365,10 +365,6 @@ en:
body_html: We have noticed some unusual or suspicious contributions to your Brave Rewards account. As a result we have temporarily frozen payments made to your account.<br /><br />Suspicious contributions can include unreasonably large contributions for small channels and/or contribution that solely originate from the user growth pool.<br /><br />Please contact us at <a href="support+publishers@basicattentiontoken.org">support+publishers@basicattentiontoken.org</a>.
closing_html: Thank you.<br/>The Brave Rewards Team
contact_support: If you did not make this change yourself, please contact support ASAP
uphold_account_changed:
subject: Your Brave Rewards Uphold account has been updated
title: Publisher Uphold account changed
body: This email confirms your Uphold account through Brave Rewards has been updated.
uphold_kyc_incomplete:
subject: Please verify your Uphold identity
body_html: |
Expand Down
3 changes: 0 additions & 3 deletions test/mailers/previews/publisher_mailer_preview.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,6 @@ def verification_done
PublisherMailer.verification_done(Channel.first)
end

def uphold_account_changed
PublisherMailer.uphold_account_changed(Publisher.first)
end

def wallet_not_connected
PublisherMailer.wallet_not_connected(Publisher.first)
Expand Down
13 changes: 0 additions & 13 deletions test/mailers/publisher_mailer_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,6 @@ class PublisherMailerTest < ActionMailer::TestCase
Rails.application.secrets[:api_eyeshade_offline] = @prev_eyeshade_offline
end

test "uphold_account_changed" do
publisher = publishers(:default)
email = PublisherMailer.uphold_account_changed(publisher)

# # Send the email, then test that it got queued
assert_emails 1 do
email.deliver_now
end

assert_equal ['brave-publishers@localhost.local'], email.from
assert_equal [publisher.email], email.to
end

test "wallet_not_connected" do
publisher = publishers(:uphold_connected)
email = PublisherMailer.wallet_not_connected(publisher)
Expand Down

0 comments on commit 43c0374

Please sign in to comment.