diff --git a/app/mailers/invoice_mailer.rb b/app/mailers/invoice_mailer.rb index c3eb20f6f7..74821c25a9 100644 --- a/app/mailers/invoice_mailer.rb +++ b/app/mailers/invoice_mailer.rb @@ -5,7 +5,7 @@ def invoice_email(invoice_id, html, billing_email) @invoice = Invoice.find_by(id: invoice_id) billing_email ||= @invoice.billing_email return unless @invoice - return if whitelist_blocked?(@invoice.billing_email) + return if whitelist_blocked?(billing_email) kit = PDFKit.new(html) pdf = kit.to_pdf