set 'List-Unsubscribe' email header to new unsubscribe url instead of user preferences url
This commit is contained in:
parent
b8261a662b
commit
926c021125
|
@ -132,10 +132,11 @@ module Email
|
|||
def header_args
|
||||
result = {}
|
||||
if @opts[:add_unsubscribe_link]
|
||||
result['List-Unsubscribe'] = "<#{template_args[:user_preferences_url]}>"
|
||||
unsubscribe_url = @template_args[:unsubscribe_url].presence || @template_args[:user_preferences_url]
|
||||
result['List-Unsubscribe'] = "<#{unsubscribe_url}>"
|
||||
end
|
||||
|
||||
result['X-Discourse-Post-Id'] = @opts[:post_id].to_s if @opts[:post_id]
|
||||
result['X-Discourse-Post-Id'] = @opts[:post_id].to_s if @opts[:post_id]
|
||||
result['X-Discourse-Topic-Id'] = @opts[:topic_id].to_s if @opts[:topic_id]
|
||||
|
||||
if allow_reply_by_email?
|
||||
|
|
Loading…
Reference in New Issue