]> source.dussan.org Git - redmine.git/commitdiff
add empty line after guard clause to app/models/mail_handler.rb
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Thu, 5 Nov 2020 13:42:47 +0000 (13:42 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Thu, 5 Nov 2020 13:42:47 +0000 (13:42 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@20266 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/models/mail_handler.rb

index 229cfb8324ce29942e7925f6696c6526a3188921..db9358eef8b08e350e200bc2926d627c6b3e09ff 100644 (file)
@@ -297,6 +297,7 @@ class MailHandler < ActionMailer::Base
       email.attachments.each do |attachment|
         next unless accept_attachment?(attachment)
         next unless attachment.body.decoded.size > 0
+
         obj.attachments << Attachment.create(:container => obj,
                           :file => attachment.body.decoded,
                           :filename => attachment.filename,
@@ -386,11 +387,13 @@ class MailHandler < ActionMailer::Base
   def get_project_from_receiver_addresses
     local, domain = handler_options[:project_from_subaddress].to_s.split("@")
     return nil unless local && domain
+
     local = Regexp.escape(local)
 
     [:to, :cc, :bcc].each do |field|
       header = @email[field]
       next if header.blank? || header.field.blank? || !header.field.respond_to?(:addrs)
+
       header.field.addrs.each do |addr|
         if addr.domain.to_s.casecmp(domain)==0 && addr.local.to_s =~ /\A#{local}\+([^+]+)\z/
           if project = Project.find_by_identifier($1)
@@ -416,6 +419,7 @@ class MailHandler < ActionMailer::Base
       end
     end
     raise MissingInformation, 'Unable to determine target project' if target.nil?
+
     target
   end