]> source.dussan.org Git - redmine.git/commitdiff
Remove redefinition of ActionMailer::LogSubscriber#deliver which is no longer necessa...
authorGo MAEDA <maeda@farend.jp>
Thu, 19 Aug 2021 13:53:07 +0000 (13:53 +0000)
committerGo MAEDA <maeda@farend.jp>
Thu, 19 Aug 2021 13:53:07 +0000 (13:53 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@21197 e93f8b46-1217-0410-a6f0-8f06a7374b81

config/initializers/10-patches.rb

index 643d06b7ea6a4615d45117f4f4bd8ce7decc8955..5788091b5e407c2e17205cc1d2d5387774e11030 100644 (file)
@@ -124,24 +124,6 @@ end
 
 ActionMailer::Base.add_delivery_method :tmp_file, DeliveryMethods::TmpFile
 
-# Changes how sent emails are logged
-# Rails doesn't log cc and bcc which is misleading when using bcc only (#12090)
-module ActionMailer
-  class LogSubscriber < ActiveSupport::LogSubscriber
-    def deliver(event)
-      recipients = [:to, :cc, :bcc].inject(+"") do |s, header|
-        r = Array.wrap(event.payload[header])
-        if r.any?
-          s << "\n  #{header}: #{r.join(', ')}"
-        end
-        s
-      end
-      info("\nSent email \"#{event.payload[:subject]}\" (%1.fms)#{recipients}" % event.duration)
-      debug(event.payload[:mail])
-    end
-  end
-end
-
 module ActionController
   module MimeResponds
     class Collector