actionmailer 7.1.3 → 7.2.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
 - data/CHANGELOG.md +10 -146
 - data/lib/action_mailer/base.rb +5 -6
 - data/lib/action_mailer/delivery_methods.rb +1 -2
 - data/lib/action_mailer/gem_version.rb +3 -3
 - data/lib/action_mailer/mail_helper.rb +11 -3
 - data/lib/action_mailer/parameterized.rb +5 -7
 - data/lib/action_mailer/preview.rb +0 -24
 - data/lib/action_mailer/test_helper.rb +0 -20
 - data/lib/action_mailer.rb +1 -1
 - data/lib/rails/generators/mailer/templates/mailer.rb.tt +3 -1
 - metadata +20 -68
 
    
        checksums.yaml
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            ---
         
     | 
| 
       2 
2 
     | 
    
         
             
            SHA256:
         
     | 
| 
       3 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       4 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 3 
     | 
    
         
            +
              metadata.gz: dead7aa73f10df3907e7314902d2bb322b089bc0d4e22d01e916e9cf7ecd4c18
         
     | 
| 
      
 4 
     | 
    
         
            +
              data.tar.gz: e8477ce5f9c8795700aeb5ab20b7f8d3581df9aeaefcdb5bac3d9587770f0600
         
     | 
| 
       5 
5 
     | 
    
         
             
            SHA512:
         
     | 
| 
       6 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       7 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 6 
     | 
    
         
            +
              metadata.gz: b73dae035cf3b87e7f4e67a32c7f968edfd29bd2b692887175d9087151fac4e4ec13cff35b6c32659fd3511f770ddbd2c668a55d39b38fbffb1f4cbd4e705c28
         
     | 
| 
      
 7 
     | 
    
         
            +
              data.tar.gz: af0abdca9964dbcf323908273817327ffc89fd4e4da37643ba55c230a6536a6ede26e3599c82b2ae4ae3176ba98c6f3dd3fa383f63f6c8f031390b73c68dcd39
         
     | 
    
        data/CHANGELOG.md
    CHANGED
    
    | 
         @@ -1,158 +1,22 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            ## Rails 7.1. 
     | 
| 
      
 1 
     | 
    
         
            +
            ## Rails 7.2.1.1 (October 15, 2024) ##
         
     | 
| 
       2 
2 
     | 
    
         | 
| 
       3 
     | 
    
         
            -
            *    
     | 
| 
       4 
     | 
    
         
            -
             
     | 
| 
       5 
     | 
    
         
            -
             
     | 
| 
       6 
     | 
    
         
            -
            ## Rails 7.1.2 (November 10, 2023) ##
         
     | 
| 
       7 
     | 
    
         
            -
             
     | 
| 
       8 
     | 
    
         
            -
            *   No changes.
         
     | 
| 
       9 
     | 
    
         
            -
             
     | 
| 
       10 
     | 
    
         
            -
             
     | 
| 
       11 
     | 
    
         
            -
            ## Rails 7.1.1 (October 11, 2023) ##
         
     | 
| 
       12 
     | 
    
         
            -
             
     | 
| 
       13 
     | 
    
         
            -
            *   No changes.
         
     | 
| 
       14 
     | 
    
         
            -
             
     | 
| 
       15 
     | 
    
         
            -
             
     | 
| 
       16 
     | 
    
         
            -
            ## Rails 7.1.0 (October 05, 2023) ##
         
     | 
| 
       17 
     | 
    
         
            -
             
     | 
| 
       18 
     | 
    
         
            -
            *   No changes.
         
     | 
| 
      
 3 
     | 
    
         
            +
            *   Avoid regex backtracking in `block_format` helper
         
     | 
| 
       19 
4 
     | 
    
         | 
| 
      
 5 
     | 
    
         
            +
                [CVE-2024-47889]
         
     | 
| 
       20 
6 
     | 
    
         | 
| 
       21 
     | 
    
         
            -
            ## Rails 7.1 
     | 
| 
      
 7 
     | 
    
         
            +
            ## Rails 7.2.1 (August 22, 2024) ##
         
     | 
| 
       22 
8 
     | 
    
         | 
| 
       23 
9 
     | 
    
         
             
            *   No changes.
         
     | 
| 
       24 
10 
     | 
    
         | 
| 
       25 
11 
     | 
    
         | 
| 
       26 
     | 
    
         
            -
            ## Rails 7. 
     | 
| 
       27 
     | 
    
         
            -
             
     | 
| 
       28 
     | 
    
         
            -
            *   Introduce `ActionMailer::FormBuilder`
         
     | 
| 
       29 
     | 
    
         
            -
             
     | 
| 
       30 
     | 
    
         
            -
                Use the `default_form_builder` method in mailers to set the default form builder
         
     | 
| 
       31 
     | 
    
         
            -
                for templates rendered by that mailer. Matches the behaviour in Action Controller.
         
     | 
| 
       32 
     | 
    
         
            -
             
     | 
| 
       33 
     | 
    
         
            -
                *Alex Ghiculescu*
         
     | 
| 
       34 
     | 
    
         
            -
             
     | 
| 
       35 
     | 
    
         
            -
             
     | 
| 
       36 
     | 
    
         
            -
            ## Rails 7.1.0.beta1 (September 13, 2023) ##
         
     | 
| 
       37 
     | 
    
         
            -
             
     | 
| 
       38 
     | 
    
         
            -
            *   Mailers are listed in alphabetical order on the mailer preview page now.
         
     | 
| 
       39 
     | 
    
         
            -
             
     | 
| 
       40 
     | 
    
         
            -
                *Martin Spickermann*
         
     | 
| 
       41 
     | 
    
         
            -
             
     | 
| 
       42 
     | 
    
         
            -
            *   Deprecate passing params to `assert_enqueued_email_with` via the `:args`
         
     | 
| 
       43 
     | 
    
         
            -
                kwarg. `assert_enqueued_email_with` now supports a `:params` kwarg, so use
         
     | 
| 
       44 
     | 
    
         
            -
                that to pass params:
         
     | 
| 
       45 
     | 
    
         
            -
             
     | 
| 
       46 
     | 
    
         
            -
                ```ruby
         
     | 
| 
       47 
     | 
    
         
            -
                # BEFORE
         
     | 
| 
       48 
     | 
    
         
            -
                assert_enqueued_email_with MyMailer, :my_method, args: { my_param: "value" }
         
     | 
| 
       49 
     | 
    
         
            -
             
     | 
| 
       50 
     | 
    
         
            -
                # AFTER
         
     | 
| 
       51 
     | 
    
         
            -
                assert_enqueued_email_with MyMailer, :my_method, params: { my_param: "value" }
         
     | 
| 
       52 
     | 
    
         
            -
                ```
         
     | 
| 
       53 
     | 
    
         
            -
             
     | 
| 
       54 
     | 
    
         
            -
                To specify named mailer args as a Hash, wrap the Hash in an array:
         
     | 
| 
       55 
     | 
    
         
            -
             
     | 
| 
       56 
     | 
    
         
            -
                ```ruby
         
     | 
| 
       57 
     | 
    
         
            -
                assert_enqueued_email_with MyMailer, :my_method, args: [{ my_arg: "value" }]
         
     | 
| 
       58 
     | 
    
         
            -
                # OR
         
     | 
| 
       59 
     | 
    
         
            -
                assert_enqueued_email_with MyMailer, :my_method, args: [my_arg: "value"]
         
     | 
| 
       60 
     | 
    
         
            -
                ```
         
     | 
| 
       61 
     | 
    
         
            -
             
     | 
| 
       62 
     | 
    
         
            -
                *Jonathan Hefner*
         
     | 
| 
       63 
     | 
    
         
            -
             
     | 
| 
       64 
     | 
    
         
            -
            *   Accept procs for args and params in `assert_enqueued_email_with`
         
     | 
| 
       65 
     | 
    
         
            -
             
     | 
| 
       66 
     | 
    
         
            -
                ```ruby
         
     | 
| 
       67 
     | 
    
         
            -
                assert_enqueued_email_with DeliveryJob, params: -> p { p[:token] =~ /\w+/ } do
         
     | 
| 
       68 
     | 
    
         
            -
                  UserMailer.with(token: user.generate_token).email_verification.deliver_later
         
     | 
| 
       69 
     | 
    
         
            -
                end
         
     | 
| 
       70 
     | 
    
         
            -
                ```
         
     | 
| 
       71 
     | 
    
         
            -
             
     | 
| 
       72 
     | 
    
         
            -
                *Max Chernyak*
         
     | 
| 
       73 
     | 
    
         
            -
             
     | 
| 
       74 
     | 
    
         
            -
            *   Added `*_deliver` callbacks to `ActionMailer::Base` that wrap mail message delivery.
         
     | 
| 
       75 
     | 
    
         
            -
             
     | 
| 
       76 
     | 
    
         
            -
                Example:
         
     | 
| 
       77 
     | 
    
         
            -
             
     | 
| 
       78 
     | 
    
         
            -
                ```ruby
         
     | 
| 
       79 
     | 
    
         
            -
                class EventsMailer < ApplicationMailer
         
     | 
| 
       80 
     | 
    
         
            -
                  after_deliver do
         
     | 
| 
       81 
     | 
    
         
            -
                    User.find_by(email: message.to.first).update(email_provider_id: message.message_id, emailed_at: Time.current)
         
     | 
| 
       82 
     | 
    
         
            -
                  end
         
     | 
| 
       83 
     | 
    
         
            -
                end
         
     | 
| 
       84 
     | 
    
         
            -
                ```
         
     | 
| 
       85 
     | 
    
         
            -
             
     | 
| 
       86 
     | 
    
         
            -
                *Ben Sheldon*
         
     | 
| 
       87 
     | 
    
         
            -
             
     | 
| 
       88 
     | 
    
         
            -
            *   Added `deliver_enqueued_emails` to `ActionMailer::TestHelper`. This method
         
     | 
| 
       89 
     | 
    
         
            -
                delivers all enqueued email jobs.
         
     | 
| 
       90 
     | 
    
         
            -
             
     | 
| 
       91 
     | 
    
         
            -
                Example:
         
     | 
| 
       92 
     | 
    
         
            -
             
     | 
| 
       93 
     | 
    
         
            -
                ```ruby
         
     | 
| 
       94 
     | 
    
         
            -
                def test_deliver_enqueued_emails
         
     | 
| 
       95 
     | 
    
         
            -
                  deliver_enqueued_emails do
         
     | 
| 
       96 
     | 
    
         
            -
                    ContactMailer.welcome.deliver_later
         
     | 
| 
       97 
     | 
    
         
            -
                  end
         
     | 
| 
       98 
     | 
    
         
            -
                  assert_emails 1
         
     | 
| 
       99 
     | 
    
         
            -
                end
         
     | 
| 
       100 
     | 
    
         
            -
                ```
         
     | 
| 
       101 
     | 
    
         
            -
             
     | 
| 
       102 
     | 
    
         
            -
                *Andrew Novoselac*
         
     | 
| 
       103 
     | 
    
         
            -
             
     | 
| 
       104 
     | 
    
         
            -
            *   The `deliver_later_queue_name` used by the default mailer job can now be
         
     | 
| 
       105 
     | 
    
         
            -
                configured on a per-mailer basis. Previously this was only configurable
         
     | 
| 
       106 
     | 
    
         
            -
                for all mailers via `ActionMailer::Base`.
         
     | 
| 
       107 
     | 
    
         
            -
             
     | 
| 
       108 
     | 
    
         
            -
                Example:
         
     | 
| 
       109 
     | 
    
         
            -
             
     | 
| 
       110 
     | 
    
         
            -
                ```ruby
         
     | 
| 
       111 
     | 
    
         
            -
                class EventsMailer < ApplicationMailer
         
     | 
| 
       112 
     | 
    
         
            -
                  self.deliver_later_queue_name = :throttled_mailer
         
     | 
| 
       113 
     | 
    
         
            -
                end
         
     | 
| 
       114 
     | 
    
         
            -
                ```
         
     | 
| 
       115 
     | 
    
         
            -
             
     | 
| 
       116 
     | 
    
         
            -
                *Jeffrey Hardy*
         
     | 
| 
       117 
     | 
    
         
            -
             
     | 
| 
       118 
     | 
    
         
            -
            *   Email previews now include an expandable section to show all headers.
         
     | 
| 
       119 
     | 
    
         
            -
             
     | 
| 
       120 
     | 
    
         
            -
                Headers like `Message-ID` for threading or email service provider specific
         
     | 
| 
       121 
     | 
    
         
            -
                features like analytics tags or account metadata can now be viewed directly
         
     | 
| 
       122 
     | 
    
         
            -
                in the mailer preview.
         
     | 
| 
       123 
     | 
    
         
            -
             
     | 
| 
       124 
     | 
    
         
            -
                *Matt Swanson*
         
     | 
| 
       125 
     | 
    
         
            -
             
     | 
| 
       126 
     | 
    
         
            -
            *   Default `ActionMailer::Parameterized#params` to an empty `Hash`
         
     | 
| 
       127 
     | 
    
         
            -
             
     | 
| 
       128 
     | 
    
         
            -
                *Sean Doyle*
         
     | 
| 
       129 
     | 
    
         
            -
             
     | 
| 
       130 
     | 
    
         
            -
            *   Introduce the `capture_emails` test helper.
         
     | 
| 
       131 
     | 
    
         
            -
             
     | 
| 
       132 
     | 
    
         
            -
                Returns all emails that are sent in a block.
         
     | 
| 
       133 
     | 
    
         
            -
             
     | 
| 
       134 
     | 
    
         
            -
                ```ruby
         
     | 
| 
       135 
     | 
    
         
            -
                def test_emails
         
     | 
| 
       136 
     | 
    
         
            -
                  emails = capture_emails do
         
     | 
| 
       137 
     | 
    
         
            -
                    ContactMailer.welcome.deliver_now
         
     | 
| 
       138 
     | 
    
         
            -
                    ContactMailer.welcome.deliver_later
         
     | 
| 
       139 
     | 
    
         
            -
                  end
         
     | 
| 
       140 
     | 
    
         
            -
                  assert_email "Hi there", emails.first.subject
         
     | 
| 
       141 
     | 
    
         
            -
                end
         
     | 
| 
       142 
     | 
    
         
            -
                ```
         
     | 
| 
       143 
     | 
    
         
            -
             
     | 
| 
       144 
     | 
    
         
            -
                *Alex Ghiculescu*
         
     | 
| 
       145 
     | 
    
         
            -
             
     | 
| 
       146 
     | 
    
         
            -
            *   Added ability to download `.eml` file for the email preview.
         
     | 
| 
      
 12 
     | 
    
         
            +
            ## Rails 7.2.0 (August 09, 2024) ##
         
     | 
| 
       147 
13 
     | 
    
         | 
| 
       148 
     | 
    
         
            -
             
     | 
| 
      
 14 
     | 
    
         
            +
            *   Remove deprecated params via `:args` for `assert_enqueued_email_with`.
         
     | 
| 
       149 
15 
     | 
    
         | 
| 
       150 
     | 
    
         
            -
            * 
     | 
| 
      
 16 
     | 
    
         
            +
                *Rafael Mendonça França*
         
     | 
| 
       151 
17 
     | 
    
         | 
| 
       152 
     | 
    
         
            -
             
     | 
| 
       153 
     | 
    
         
            -
                `config.action_mailer.preview_paths`. Appending paths to this configuration option
         
     | 
| 
       154 
     | 
    
         
            -
                will cause those paths to be used in the search for mailer previews.
         
     | 
| 
      
 18 
     | 
    
         
            +
            *   Remove deprecated `config.action_mailer.preview_path`.
         
     | 
| 
       155 
19 
     | 
    
         | 
| 
       156 
     | 
    
         
            -
                * 
     | 
| 
      
 20 
     | 
    
         
            +
                *Rafael Mendonça França*
         
     | 
| 
       157 
21 
     | 
    
         | 
| 
       158 
     | 
    
         
            -
            Please check [7- 
     | 
| 
      
 22 
     | 
    
         
            +
            Please check [7-1-stable](https://github.com/rails/rails/blob/7-1-stable/actionmailer/CHANGELOG.md) for previous changes.
         
     | 
    
        data/lib/action_mailer/base.rb
    CHANGED
    
    | 
         @@ -625,17 +625,16 @@ module ActionMailer 
     | 
|
| 
       625 
625 
     | 
    
         
             
                    payload[:perform_deliveries] = mail.perform_deliveries
         
     | 
| 
       626 
626 
     | 
    
         
             
                  end
         
     | 
| 
       627 
627 
     | 
    
         | 
| 
       628 
     | 
    
         
            -
                  def method_missing(method_name,  
     | 
| 
       629 
     | 
    
         
            -
                    if action_methods.include?(method_name. 
     | 
| 
       630 
     | 
    
         
            -
                      MessageDelivery.new(self, method_name,  
     | 
| 
      
 628 
     | 
    
         
            +
                  def method_missing(method_name, ...)
         
     | 
| 
      
 629 
     | 
    
         
            +
                    if action_methods.include?(method_name.name)
         
     | 
| 
      
 630 
     | 
    
         
            +
                      MessageDelivery.new(self, method_name, ...)
         
     | 
| 
       631 
631 
     | 
    
         
             
                    else
         
     | 
| 
       632 
632 
     | 
    
         
             
                      super
         
     | 
| 
       633 
633 
     | 
    
         
             
                    end
         
     | 
| 
       634 
634 
     | 
    
         
             
                  end
         
     | 
| 
       635 
     | 
    
         
            -
                  ruby2_keywords(:method_missing)
         
     | 
| 
       636 
635 
     | 
    
         | 
| 
       637 
636 
     | 
    
         
             
                  def respond_to_missing?(method, include_all = false)
         
     | 
| 
       638 
     | 
    
         
            -
                    action_methods.include?(method. 
     | 
| 
      
 637 
     | 
    
         
            +
                    action_methods.include?(method.name) || super
         
     | 
| 
       639 
638 
     | 
    
         
             
                  end
         
     | 
| 
       640 
639 
     | 
    
         
             
                end
         
     | 
| 
       641 
640 
     | 
    
         | 
| 
         @@ -669,7 +668,7 @@ module ActionMailer 
     | 
|
| 
       669 
668 
     | 
    
         
             
                    true
         
     | 
| 
       670 
669 
     | 
    
         
             
                  end
         
     | 
| 
       671 
670 
     | 
    
         | 
| 
       672 
     | 
    
         
            -
                  def method_missing( 
     | 
| 
      
 671 
     | 
    
         
            +
                  def method_missing(...)
         
     | 
| 
       673 
672 
     | 
    
         
             
                    nil
         
     | 
| 
       674 
673 
     | 
    
         
             
                  end
         
     | 
| 
       675 
674 
     | 
    
         
             
                end
         
     | 
| 
         @@ -32,8 +32,7 @@ module ActionMailer 
     | 
|
| 
       32 
32 
     | 
    
         | 
| 
       33 
33 
     | 
    
         
             
                  add_delivery_method :sendmail, Mail::Sendmail,
         
     | 
| 
       34 
34 
     | 
    
         
             
                    location:  "/usr/sbin/sendmail",
         
     | 
| 
       35 
     | 
    
         
            -
                     
     | 
| 
       36 
     | 
    
         
            -
                    arguments: Gem::Version.new(Mail::VERSION.version) >= Gem::Version.new("2.8.0") ? %w[-i] : "-i"
         
     | 
| 
      
 35 
     | 
    
         
            +
                    arguments: %w[-i]
         
     | 
| 
       37 
36 
     | 
    
         | 
| 
       38 
37 
     | 
    
         
             
                  add_delivery_method :test, Mail::TestMailer
         
     | 
| 
       39 
38 
     | 
    
         
             
                end
         
     | 
| 
         @@ -25,10 +25,18 @@ module ActionMailer 
     | 
|
| 
       25 
25 
     | 
    
         
             
                  }.join("\n\n")
         
     | 
| 
       26 
26 
     | 
    
         | 
| 
       27 
27 
     | 
    
         
             
                  # Make list points stand on their own line
         
     | 
| 
       28 
     | 
    
         
            -
                   
     | 
| 
       29 
     | 
    
         
            -
                  formatted. 
     | 
| 
      
 28 
     | 
    
         
            +
                  output = +""
         
     | 
| 
      
 29 
     | 
    
         
            +
                  splits = formatted.split(/(\*+|\#+)/)
         
     | 
| 
      
 30 
     | 
    
         
            +
                  while line = splits.shift
         
     | 
| 
      
 31 
     | 
    
         
            +
                    if line.start_with?("*", "#") && splits[0].start_with?(" ")
         
     | 
| 
      
 32 
     | 
    
         
            +
                      output.chomp!(" ") while output.end_with?(" ")
         
     | 
| 
      
 33 
     | 
    
         
            +
                      output << "  #{line} #{splits.shift.strip}\n"
         
     | 
| 
      
 34 
     | 
    
         
            +
                    else
         
     | 
| 
      
 35 
     | 
    
         
            +
                      output << line
         
     | 
| 
      
 36 
     | 
    
         
            +
                    end
         
     | 
| 
      
 37 
     | 
    
         
            +
                  end
         
     | 
| 
       30 
38 
     | 
    
         | 
| 
       31 
     | 
    
         
            -
                   
     | 
| 
      
 39 
     | 
    
         
            +
                  output
         
     | 
| 
       32 
40 
     | 
    
         
             
                end
         
     | 
| 
       33 
41 
     | 
    
         | 
| 
       34 
42 
     | 
    
         
             
                # Access the mailer instance.
         
     | 
| 
         @@ -114,14 +114,13 @@ module ActionMailer 
     | 
|
| 
       114 
114 
     | 
    
         
             
                  end
         
     | 
| 
       115 
115 
     | 
    
         | 
| 
       116 
116 
     | 
    
         
             
                  private
         
     | 
| 
       117 
     | 
    
         
            -
                    def method_missing(method_name,  
     | 
| 
       118 
     | 
    
         
            -
                      if @mailer.action_methods.include?(method_name. 
     | 
| 
       119 
     | 
    
         
            -
                        ActionMailer::Parameterized::MessageDelivery.new(@mailer, method_name, @params,  
     | 
| 
      
 117 
     | 
    
         
            +
                    def method_missing(method_name, ...)
         
     | 
| 
      
 118 
     | 
    
         
            +
                      if @mailer.action_methods.include?(method_name.name)
         
     | 
| 
      
 119 
     | 
    
         
            +
                        ActionMailer::Parameterized::MessageDelivery.new(@mailer, method_name, @params, ...)
         
     | 
| 
       120 
120 
     | 
    
         
             
                      else
         
     | 
| 
       121 
121 
     | 
    
         
             
                        super
         
     | 
| 
       122 
122 
     | 
    
         
             
                      end
         
     | 
| 
       123 
123 
     | 
    
         
             
                    end
         
     | 
| 
       124 
     | 
    
         
            -
                    ruby2_keywords(:method_missing)
         
     | 
| 
       125 
124 
     | 
    
         | 
| 
       126 
125 
     | 
    
         
             
                    def respond_to_missing?(method, include_all = false)
         
     | 
| 
       127 
126 
     | 
    
         
             
                      @mailer.respond_to?(method, include_all)
         
     | 
| 
         @@ -129,11 +128,10 @@ module ActionMailer 
     | 
|
| 
       129 
128 
     | 
    
         
             
                end
         
     | 
| 
       130 
129 
     | 
    
         | 
| 
       131 
130 
     | 
    
         
             
                class MessageDelivery < ActionMailer::MessageDelivery # :nodoc:
         
     | 
| 
       132 
     | 
    
         
            -
                  def initialize(mailer_class, action, params,  
     | 
| 
       133 
     | 
    
         
            -
                    super(mailer_class, action,  
     | 
| 
      
 131 
     | 
    
         
            +
                  def initialize(mailer_class, action, params, ...)
         
     | 
| 
      
 132 
     | 
    
         
            +
                    super(mailer_class, action, ...)
         
     | 
| 
       134 
133 
     | 
    
         
             
                    @params = params
         
     | 
| 
       135 
134 
     | 
    
         
             
                  end
         
     | 
| 
       136 
     | 
    
         
            -
                  ruby2_keywords(:initialize)
         
     | 
| 
       137 
135 
     | 
    
         | 
| 
       138 
136 
     | 
    
         
             
                  private
         
     | 
| 
       139 
137 
     | 
    
         
             
                    def processed_mailer
         
     | 
| 
         @@ -25,31 +25,7 @@ module ActionMailer 
     | 
|
| 
       25 
25 
     | 
    
         
             
                  mattr_accessor :preview_interceptors, instance_writer: false, default: [ActionMailer::InlinePreviewInterceptor]
         
     | 
| 
       26 
26 
     | 
    
         
             
                end
         
     | 
| 
       27 
27 
     | 
    
         | 
| 
       28 
     | 
    
         
            -
                def preview_path
         
     | 
| 
       29 
     | 
    
         
            -
                  ActionMailer.deprecator.warn(<<-MSG.squish)
         
     | 
| 
       30 
     | 
    
         
            -
                    Using preview_path option is deprecated and will be removed in Rails 7.2.
         
     | 
| 
       31 
     | 
    
         
            -
                    Please use preview_paths instead.
         
     | 
| 
       32 
     | 
    
         
            -
                  MSG
         
     | 
| 
       33 
     | 
    
         
            -
                  self.class.preview_paths.first
         
     | 
| 
       34 
     | 
    
         
            -
                end
         
     | 
| 
       35 
     | 
    
         
            -
             
     | 
| 
       36 
28 
     | 
    
         
             
                module ClassMethods
         
     | 
| 
       37 
     | 
    
         
            -
                  def preview_path=(value)
         
     | 
| 
       38 
     | 
    
         
            -
                    ActionMailer.deprecator.warn(<<-MSG.squish)
         
     | 
| 
       39 
     | 
    
         
            -
                      Using preview_path= option is deprecated and will be removed in Rails 7.2.
         
     | 
| 
       40 
     | 
    
         
            -
                      Please use preview_paths= instead.
         
     | 
| 
       41 
     | 
    
         
            -
                    MSG
         
     | 
| 
       42 
     | 
    
         
            -
                    self.preview_paths << value
         
     | 
| 
       43 
     | 
    
         
            -
                  end
         
     | 
| 
       44 
     | 
    
         
            -
             
     | 
| 
       45 
     | 
    
         
            -
                  def preview_path
         
     | 
| 
       46 
     | 
    
         
            -
                    ActionMailer.deprecator.warn(<<-MSG.squish)
         
     | 
| 
       47 
     | 
    
         
            -
                      Using preview_path option is deprecated and will be removed in Rails 7.2.
         
     | 
| 
       48 
     | 
    
         
            -
                      Please use preview_paths instead.
         
     | 
| 
       49 
     | 
    
         
            -
                    MSG
         
     | 
| 
       50 
     | 
    
         
            -
                    self.preview_paths.first
         
     | 
| 
       51 
     | 
    
         
            -
                  end
         
     | 
| 
       52 
     | 
    
         
            -
             
     | 
| 
       53 
29 
     | 
    
         
             
                  # Register one or more Interceptors which will be called before mail is previewed.
         
     | 
| 
       54 
30 
     | 
    
         
             
                  def register_preview_interceptors(*interceptors)
         
     | 
| 
       55 
31 
     | 
    
         
             
                    interceptors.flatten.compact.each { |interceptor| register_preview_interceptor(interceptor) }
         
     | 
| 
         @@ -160,26 +160,6 @@ module ActionMailer 
     | 
|
| 
       160 
160 
     | 
    
         
             
                    mailer = mailer.instance_variable_get(:@mailer)
         
     | 
| 
       161 
161 
     | 
    
         
             
                  end
         
     | 
| 
       162 
162 
     | 
    
         | 
| 
       163 
     | 
    
         
            -
                  if args.is_a?(Hash)
         
     | 
| 
       164 
     | 
    
         
            -
                    ActionMailer.deprecator.warn <<~MSG
         
     | 
| 
       165 
     | 
    
         
            -
                      Passing a Hash to the assert_enqueued_email_with :args kwarg causes the
         
     | 
| 
       166 
     | 
    
         
            -
                      Hash to be treated as params. This behavior is deprecated and will be
         
     | 
| 
       167 
     | 
    
         
            -
                      removed in Rails 7.2.
         
     | 
| 
       168 
     | 
    
         
            -
             
     | 
| 
       169 
     | 
    
         
            -
                      To specify a params Hash, use the :params kwarg:
         
     | 
| 
       170 
     | 
    
         
            -
             
     | 
| 
       171 
     | 
    
         
            -
                        assert_enqueued_email_with MyMailer, :my_method, params: { my_param: "value" }
         
     | 
| 
       172 
     | 
    
         
            -
             
     | 
| 
       173 
     | 
    
         
            -
                      Or, to specify named mailer args as a Hash, wrap the Hash in an array:
         
     | 
| 
       174 
     | 
    
         
            -
             
     | 
| 
       175 
     | 
    
         
            -
                        assert_enqueued_email_with MyMailer, :my_method, args: [{ my_arg: "value" }]
         
     | 
| 
       176 
     | 
    
         
            -
                        # OR
         
     | 
| 
       177 
     | 
    
         
            -
                        assert_enqueued_email_with MyMailer, :my_method, args: [my_arg: "value"]
         
     | 
| 
       178 
     | 
    
         
            -
                    MSG
         
     | 
| 
       179 
     | 
    
         
            -
             
     | 
| 
       180 
     | 
    
         
            -
                    params, args = args, nil
         
     | 
| 
       181 
     | 
    
         
            -
                  end
         
     | 
| 
       182 
     | 
    
         
            -
             
     | 
| 
       183 
163 
     | 
    
         
             
                  args = Array(args) unless args.is_a?(Proc)
         
     | 
| 
       184 
164 
     | 
    
         
             
                  queue ||= mailer.deliver_later_queue_name || ActiveJob::Base.default_queue_name
         
     | 
| 
       185 
165 
     | 
    
         | 
    
        data/lib/action_mailer.rb
    CHANGED
    
    | 
         @@ -35,7 +35,7 @@ require "active_support/core_ext/module/attr_internal" 
     | 
|
| 
       35 
35 
     | 
    
         
             
            require "active_support/core_ext/string/inflections"
         
     | 
| 
       36 
36 
     | 
    
         
             
            require "active_support/lazy_load_hooks"
         
     | 
| 
       37 
37 
     | 
    
         | 
| 
       38 
     | 
    
         
            -
            # :include:  
     | 
| 
      
 38 
     | 
    
         
            +
            # :include: ../README.rdoc
         
     | 
| 
       39 
39 
     | 
    
         
             
            module ActionMailer
         
     | 
| 
       40 
40 
     | 
    
         
             
              extend ::ActiveSupport::Autoload
         
     | 
| 
       41 
41 
     | 
    
         | 
| 
         @@ -1,7 +1,9 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            <% module_namespacing do -%>
         
     | 
| 
       2 
2 
     | 
    
         
             
            class <%= class_name %>Mailer < ApplicationMailer
         
     | 
| 
       3 
     | 
    
         
            -
            <% actions. 
     | 
| 
      
 3 
     | 
    
         
            +
            <% actions.each_with_index do |action, index| -%>
         
     | 
| 
      
 4 
     | 
    
         
            +
            <% if index != 0 -%>
         
     | 
| 
       4 
5 
     | 
    
         | 
| 
      
 6 
     | 
    
         
            +
            <% end -%>
         
     | 
| 
       5 
7 
     | 
    
         
             
              # Subject can be set in your I18n file at config/locales/en.yml
         
     | 
| 
       6 
8 
     | 
    
         
             
              # with the following lookup:
         
     | 
| 
       7 
9 
     | 
    
         
             
              #
         
     | 
    
        metadata
    CHANGED
    
    | 
         @@ -1,14 +1,14 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: actionmailer
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version
         
     | 
| 
       4 
     | 
    
         
            -
              version: 7.1. 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 7.2.1.1
         
     | 
| 
       5 
5 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
6 
     | 
    
         
             
            authors:
         
     | 
| 
       7 
7 
     | 
    
         
             
            - David Heinemeier Hansson
         
     | 
| 
       8 
     | 
    
         
            -
            autorequire:
         
     | 
| 
      
 8 
     | 
    
         
            +
            autorequire: 
         
     | 
| 
       9 
9 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       10 
10 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       11 
     | 
    
         
            -
            date: 2024- 
     | 
| 
      
 11 
     | 
    
         
            +
            date: 2024-10-15 00:00:00.000000000 Z
         
     | 
| 
       12 
12 
     | 
    
         
             
            dependencies:
         
     | 
| 
       13 
13 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       14 
14 
     | 
    
         
             
              name: activesupport
         
     | 
| 
         @@ -16,118 +16,70 @@ dependencies: 
     | 
|
| 
       16 
16 
     | 
    
         
             
                requirements:
         
     | 
| 
       17 
17 
     | 
    
         
             
                - - '='
         
     | 
| 
       18 
18 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       19 
     | 
    
         
            -
                    version: 7.1. 
     | 
| 
      
 19 
     | 
    
         
            +
                    version: 7.2.1.1
         
     | 
| 
       20 
20 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       21 
21 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       22 
22 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       23 
23 
     | 
    
         
             
                requirements:
         
     | 
| 
       24 
24 
     | 
    
         
             
                - - '='
         
     | 
| 
       25 
25 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       26 
     | 
    
         
            -
                    version: 7.1. 
     | 
| 
      
 26 
     | 
    
         
            +
                    version: 7.2.1.1
         
     | 
| 
       27 
27 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       28 
28 
     | 
    
         
             
              name: actionpack
         
     | 
| 
       29 
29 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
       30 
30 
     | 
    
         
             
                requirements:
         
     | 
| 
       31 
31 
     | 
    
         
             
                - - '='
         
     | 
| 
       32 
32 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       33 
     | 
    
         
            -
                    version: 7.1. 
     | 
| 
      
 33 
     | 
    
         
            +
                    version: 7.2.1.1
         
     | 
| 
       34 
34 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       35 
35 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       36 
36 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       37 
37 
     | 
    
         
             
                requirements:
         
     | 
| 
       38 
38 
     | 
    
         
             
                - - '='
         
     | 
| 
       39 
39 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       40 
     | 
    
         
            -
                    version: 7.1. 
     | 
| 
      
 40 
     | 
    
         
            +
                    version: 7.2.1.1
         
     | 
| 
       41 
41 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       42 
42 
     | 
    
         
             
              name: actionview
         
     | 
| 
       43 
43 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
       44 
44 
     | 
    
         
             
                requirements:
         
     | 
| 
       45 
45 
     | 
    
         
             
                - - '='
         
     | 
| 
       46 
46 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       47 
     | 
    
         
            -
                    version: 7.1. 
     | 
| 
      
 47 
     | 
    
         
            +
                    version: 7.2.1.1
         
     | 
| 
       48 
48 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       49 
49 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       50 
50 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       51 
51 
     | 
    
         
             
                requirements:
         
     | 
| 
       52 
52 
     | 
    
         
             
                - - '='
         
     | 
| 
       53 
53 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       54 
     | 
    
         
            -
                    version: 7.1. 
     | 
| 
      
 54 
     | 
    
         
            +
                    version: 7.2.1.1
         
     | 
| 
       55 
55 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       56 
56 
     | 
    
         
             
              name: activejob
         
     | 
| 
       57 
57 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
       58 
58 
     | 
    
         
             
                requirements:
         
     | 
| 
       59 
59 
     | 
    
         
             
                - - '='
         
     | 
| 
       60 
60 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       61 
     | 
    
         
            -
                    version: 7.1. 
     | 
| 
      
 61 
     | 
    
         
            +
                    version: 7.2.1.1
         
     | 
| 
       62 
62 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       63 
63 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       64 
64 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       65 
65 
     | 
    
         
             
                requirements:
         
     | 
| 
       66 
66 
     | 
    
         
             
                - - '='
         
     | 
| 
       67 
67 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       68 
     | 
    
         
            -
                    version: 7.1. 
     | 
| 
      
 68 
     | 
    
         
            +
                    version: 7.2.1.1
         
     | 
| 
       69 
69 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       70 
70 
     | 
    
         
             
              name: mail
         
     | 
| 
       71 
     | 
    
         
            -
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
       72 
     | 
    
         
            -
                requirements:
         
     | 
| 
       73 
     | 
    
         
            -
                - - "~>"
         
     | 
| 
       74 
     | 
    
         
            -
                  - !ruby/object:Gem::Version
         
     | 
| 
       75 
     | 
    
         
            -
                    version: '2.5'
         
     | 
| 
       76 
     | 
    
         
            -
                - - ">="
         
     | 
| 
       77 
     | 
    
         
            -
                  - !ruby/object:Gem::Version
         
     | 
| 
       78 
     | 
    
         
            -
                    version: 2.5.4
         
     | 
| 
       79 
     | 
    
         
            -
              type: :runtime
         
     | 
| 
       80 
     | 
    
         
            -
              prerelease: false
         
     | 
| 
       81 
     | 
    
         
            -
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       82 
     | 
    
         
            -
                requirements:
         
     | 
| 
       83 
     | 
    
         
            -
                - - "~>"
         
     | 
| 
       84 
     | 
    
         
            -
                  - !ruby/object:Gem::Version
         
     | 
| 
       85 
     | 
    
         
            -
                    version: '2.5'
         
     | 
| 
       86 
     | 
    
         
            -
                - - ">="
         
     | 
| 
       87 
     | 
    
         
            -
                  - !ruby/object:Gem::Version
         
     | 
| 
       88 
     | 
    
         
            -
                    version: 2.5.4
         
     | 
| 
       89 
     | 
    
         
            -
            - !ruby/object:Gem::Dependency
         
     | 
| 
       90 
     | 
    
         
            -
              name: net-imap
         
     | 
| 
       91 
     | 
    
         
            -
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
       92 
     | 
    
         
            -
                requirements:
         
     | 
| 
       93 
     | 
    
         
            -
                - - ">="
         
     | 
| 
       94 
     | 
    
         
            -
                  - !ruby/object:Gem::Version
         
     | 
| 
       95 
     | 
    
         
            -
                    version: '0'
         
     | 
| 
       96 
     | 
    
         
            -
              type: :runtime
         
     | 
| 
       97 
     | 
    
         
            -
              prerelease: false
         
     | 
| 
       98 
     | 
    
         
            -
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       99 
     | 
    
         
            -
                requirements:
         
     | 
| 
       100 
     | 
    
         
            -
                - - ">="
         
     | 
| 
       101 
     | 
    
         
            -
                  - !ruby/object:Gem::Version
         
     | 
| 
       102 
     | 
    
         
            -
                    version: '0'
         
     | 
| 
       103 
     | 
    
         
            -
            - !ruby/object:Gem::Dependency
         
     | 
| 
       104 
     | 
    
         
            -
              name: net-pop
         
     | 
| 
       105 
     | 
    
         
            -
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
       106 
     | 
    
         
            -
                requirements:
         
     | 
| 
       107 
     | 
    
         
            -
                - - ">="
         
     | 
| 
       108 
     | 
    
         
            -
                  - !ruby/object:Gem::Version
         
     | 
| 
       109 
     | 
    
         
            -
                    version: '0'
         
     | 
| 
       110 
     | 
    
         
            -
              type: :runtime
         
     | 
| 
       111 
     | 
    
         
            -
              prerelease: false
         
     | 
| 
       112 
     | 
    
         
            -
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       113 
     | 
    
         
            -
                requirements:
         
     | 
| 
       114 
     | 
    
         
            -
                - - ">="
         
     | 
| 
       115 
     | 
    
         
            -
                  - !ruby/object:Gem::Version
         
     | 
| 
       116 
     | 
    
         
            -
                    version: '0'
         
     | 
| 
       117 
     | 
    
         
            -
            - !ruby/object:Gem::Dependency
         
     | 
| 
       118 
     | 
    
         
            -
              name: net-smtp
         
     | 
| 
       119 
71 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
       120 
72 
     | 
    
         
             
                requirements:
         
     | 
| 
       121 
73 
     | 
    
         
             
                - - ">="
         
     | 
| 
       122 
74 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       123 
     | 
    
         
            -
                    version:  
     | 
| 
      
 75 
     | 
    
         
            +
                    version: 2.8.0
         
     | 
| 
       124 
76 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       125 
77 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       126 
78 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       127 
79 
     | 
    
         
             
                requirements:
         
     | 
| 
       128 
80 
     | 
    
         
             
                - - ">="
         
     | 
| 
       129 
81 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       130 
     | 
    
         
            -
                    version:  
     | 
| 
      
 82 
     | 
    
         
            +
                    version: 2.8.0
         
     | 
| 
       131 
83 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       132 
84 
     | 
    
         
             
              name: rails-dom-testing
         
     | 
| 
       133 
85 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
         @@ -182,12 +134,12 @@ licenses: 
     | 
|
| 
       182 
134 
     | 
    
         
             
            - MIT
         
     | 
| 
       183 
135 
     | 
    
         
             
            metadata:
         
     | 
| 
       184 
136 
     | 
    
         
             
              bug_tracker_uri: https://github.com/rails/rails/issues
         
     | 
| 
       185 
     | 
    
         
            -
              changelog_uri: https://github.com/rails/rails/blob/v7.1. 
     | 
| 
       186 
     | 
    
         
            -
              documentation_uri: https://api.rubyonrails.org/v7.1. 
     | 
| 
      
 137 
     | 
    
         
            +
              changelog_uri: https://github.com/rails/rails/blob/v7.2.1.1/actionmailer/CHANGELOG.md
         
     | 
| 
      
 138 
     | 
    
         
            +
              documentation_uri: https://api.rubyonrails.org/v7.2.1.1/
         
     | 
| 
       187 
139 
     | 
    
         
             
              mailing_list_uri: https://discuss.rubyonrails.org/c/rubyonrails-talk
         
     | 
| 
       188 
     | 
    
         
            -
              source_code_uri: https://github.com/rails/rails/tree/v7.1. 
     | 
| 
      
 140 
     | 
    
         
            +
              source_code_uri: https://github.com/rails/rails/tree/v7.2.1.1/actionmailer
         
     | 
| 
       189 
141 
     | 
    
         
             
              rubygems_mfa_required: 'true'
         
     | 
| 
       190 
     | 
    
         
            -
            post_install_message:
         
     | 
| 
      
 142 
     | 
    
         
            +
            post_install_message: 
         
     | 
| 
       191 
143 
     | 
    
         
             
            rdoc_options: []
         
     | 
| 
       192 
144 
     | 
    
         
             
            require_paths:
         
     | 
| 
       193 
145 
     | 
    
         
             
            - lib
         
     | 
| 
         @@ -195,7 +147,7 @@ required_ruby_version: !ruby/object:Gem::Requirement 
     | 
|
| 
       195 
147 
     | 
    
         
             
              requirements:
         
     | 
| 
       196 
148 
     | 
    
         
             
              - - ">="
         
     | 
| 
       197 
149 
     | 
    
         
             
                - !ruby/object:Gem::Version
         
     | 
| 
       198 
     | 
    
         
            -
                  version:  
     | 
| 
      
 150 
     | 
    
         
            +
                  version: 3.1.0
         
     | 
| 
       199 
151 
     | 
    
         
             
            required_rubygems_version: !ruby/object:Gem::Requirement
         
     | 
| 
       200 
152 
     | 
    
         
             
              requirements:
         
     | 
| 
       201 
153 
     | 
    
         
             
              - - ">="
         
     | 
| 
         @@ -203,8 +155,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement 
     | 
|
| 
       203 
155 
     | 
    
         
             
                  version: '0'
         
     | 
| 
       204 
156 
     | 
    
         
             
            requirements:
         
     | 
| 
       205 
157 
     | 
    
         
             
            - none
         
     | 
| 
       206 
     | 
    
         
            -
            rubygems_version: 3. 
     | 
| 
       207 
     | 
    
         
            -
            signing_key:
         
     | 
| 
      
 158 
     | 
    
         
            +
            rubygems_version: 3.5.16
         
     | 
| 
      
 159 
     | 
    
         
            +
            signing_key: 
         
     | 
| 
       208 
160 
     | 
    
         
             
            specification_version: 4
         
     | 
| 
       209 
161 
     | 
    
         
             
            summary: Email composition and delivery framework (part of Rails).
         
     | 
| 
       210 
162 
     | 
    
         
             
            test_files: []
         
     |