about summary refs log tree commit diff
path: root/app/mailers
diff options
context:
space:
mode:
authorQuint Guvernator <quint@guvernator.net>2018-08-26 13:22:46 -0400
committerEugen Rochko <eugen@zeonfederated.com>2018-08-26 19:22:46 +0200
commitda13fa50215c5153ee199eb8e70e7fa030523a00 (patch)
tree866797a1dd2739ff58f64c5420a557361eb8af65 /app/mailers
parenta791bac153cf979adeaf3024d65917dbd699b5d9 (diff)
Fix low-hanging rubocop gripes (#8458)
* rubocop: quit being so picky

* rubocop: miscellany

* rubocop: prefer present to blank
Diffstat (limited to 'app/mailers')
-rw-r--r--app/mailers/user_mailer.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/mailers/user_mailer.rb b/app/mailers/user_mailer.rb
index 9848c34a2..aa76b4dfe 100644
--- a/app/mailers/user_mailer.rb
+++ b/app/mailers/user_mailer.rb
@@ -16,7 +16,7 @@ class UserMailer < Devise::Mailer
     return if @resource.disabled?
 
     I18n.with_locale(@resource.locale || I18n.default_locale) do
-      mail to: @resource.unconfirmed_email.blank? ? @resource.email : @resource.unconfirmed_email,
+      mail to: @resource.unconfirmed_email.presence || @resource.email,
            subject: I18n.t(@resource.pending_reconfirmation? ? 'devise.mailer.reconfirmation_instructions.subject' : 'devise.mailer.confirmation_instructions.subject', instance: @instance),
            template_name: @resource.pending_reconfirmation? ? 'reconfirmation_instructions' : 'confirmation_instructions'
     end