Project

General

Profile

Defect #16784 ยป rev13123.patch

Toshi MARUYAMA, 2014-05-02 16:33

View differences:

lib/tasks/email.rake
55 55
END_DESC
56 56

  
57 57
    task :read => :environment do
58
      MailHandler.receive(STDIN.read, MailHandler.extract_options_from_env(ENV))
58
      Mailer.with_synched_deliveries do
59
        MailHandler.receive(STDIN.read, MailHandler.extract_options_from_env(ENV))
60
      end
59 61
    end
60 62

  
61 63
    desc <<-END_DESC
......
122 124
                      :move_on_success => ENV['move_on_success'],
123 125
                      :move_on_failure => ENV['move_on_failure']}
124 126

  
125
      Redmine::IMAP.check(imap_options, MailHandler.extract_options_from_env(ENV))
127
      Mailer.with_synched_deliveries do
128
        Redmine::IMAP.check(imap_options, MailHandler.extract_options_from_env(ENV))
129
      end
126 130
    end
127 131

  
128 132
    desc <<-END_DESC
......
149 153
                      :password => ENV['password'],
150 154
                      :delete_unprocessed => ENV['delete_unprocessed']}
151 155

  
152
      Redmine::POP3.check(pop_options, MailHandler.extract_options_from_env(ENV))
156
      Mailer.with_synched_deliveries do
157
        Redmine::POP3.check(pop_options, MailHandler.extract_options_from_env(ENV))
158
      end
153 159
    end
154 160

  
155 161
    desc "Send a test email to the user with the provided login name"
    (1-1/1)