mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-23 23:58:31 -05:00
set 'List-Unsubscribe' email header to new unsubscribe url instead of user preferences url
This commit is contained in:
parent
b8261a662b
commit
926c021125
1 changed files with 3 additions and 2 deletions
|
@ -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 a new issue