2021-06-01 12:20:20 +00:00
|
|
|
# Copyright (C) 2012-2021 Zammad Foundation, http://zammad-foundation.org/
|
|
|
|
|
2017-09-27 08:40:39 +00:00
|
|
|
class SettingSendNoAutoResponseRegExp < ActiveRecord::Migration[5.0]
|
|
|
|
def up
|
|
|
|
|
|
|
|
# return if it's a new setup
|
2020-08-03 08:35:43 +00:00
|
|
|
return if !Setting.exists?(name: 'system_init_done')
|
2017-09-27 08:40:39 +00:00
|
|
|
|
|
|
|
# improved domain name matching
|
2020-08-03 08:35:43 +00:00
|
|
|
return if !Setting.exists?(name: 'send_no_auto_response_reg_exp')
|
2018-10-09 06:17:41 +00:00
|
|
|
|
2017-09-27 08:40:39 +00:00
|
|
|
Setting.set('send_no_auto_response_reg_exp', '(mailer-daemon|postmaster|abuse|root|noreply|noreply.+?|no-reply|no-reply.+?)@.+?')
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|