1
0
mirror of https://github.com/meineerde/redmine.git synced 2025-12-22 08:21:14 +00:00

Fix: Allow to set no_notification option when receiving emails via IMAP or POP3 (#29191).

Patch by Holger Just.


git-svn-id: http://svn.redmine.org/redmine/trunk@17432 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Go MAEDA 2018-07-06 00:51:28 +00:00
parent c3081db328
commit d1c84dbdf9
2 changed files with 4 additions and 3 deletions

View File

@ -65,7 +65,7 @@ class MailHandler < ActionMailer::Base
%w(project status tracker category priority assigned_to fixed_version).each do |option| %w(project status tracker category priority assigned_to fixed_version).each do |option|
options[:issue][option.to_sym] = env[option] if env[option] options[:issue][option.to_sym] = env[option] if env[option]
end end
%w(allow_override unknown_user no_permission_check no_account_notice default_group project_from_subaddress).each do |option| %w(allow_override unknown_user no_permission_check no_account_notice no_notification default_group project_from_subaddress).each do |option|
options[option.to_sym] = env[option] if env[option] options[option.to_sym] = env[option] if env[option]
end end
if env['private'] if env['private']

View File

@ -1146,12 +1146,13 @@ class MailHandlerTest < ActiveSupport::TestCase
options = MailHandler.extract_options_from_env({ options = MailHandler.extract_options_from_env({
'tracker' => 'defect', 'tracker' => 'defect',
'project' => 'foo', 'project' => 'foo',
'unknown_user' => 'create' 'unknown_user' => 'create',
'no_notification' => '1'
}) })
assert_equal({ assert_equal({
:issue => {:tracker => 'defect', :project => 'foo'}, :issue => {:tracker => 'defect', :project => 'foo'},
:unknown_user => 'create' :unknown_user => 'create', :no_notification => '1'
}, options) }, options)
end end