diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-04-20 23:50:22 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-04-20 23:50:22 +0000 |
commit | 9dc93a4519d9d5d7be48ff274127136236a3adb3 (patch) | |
tree | 70467ae3692a0e35e5ea56bcb803eb512a10bedb /app/mailers/notify.rb | |
parent | 4b0f34b6d759d6299322b3a54453e930c6121ff0 (diff) | |
download | gitlab-ce-9dc93a4519d9d5d7be48ff274127136236a3adb3.tar.gz |
Add latest changes from gitlab-org/gitlab@13-11-stable-eev13.11.0-rc43
Diffstat (limited to 'app/mailers/notify.rb')
-rw-r--r-- | app/mailers/notify.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/mailers/notify.rb b/app/mailers/notify.rb index 8f947ea7113..5f5afef350b 100644 --- a/app/mailers/notify.rb +++ b/app/mailers/notify.rb @@ -70,7 +70,7 @@ class Notify < ApplicationMailer return unless sender = User.find(sender_id) address = default_sender_address - address.display_name = sender_name.presence || sender.name + address.display_name = sender_name.presence || "#{sender.name} (#{sender.to_reference})" if send_from_user_email && can_send_from_user_email?(sender) address.address = sender.email @@ -178,7 +178,7 @@ class Notify < ApplicationMailer headers['In-Reply-To'] = message_id(note.references.last) headers['References'] = note.references.map { |ref| message_id(ref) } - headers['X-GitLab-Discussion-ID'] = note.discussion.id if note.part_of_discussion? + headers['X-GitLab-Discussion-ID'] = note.discussion.id if note.part_of_discussion? || note.can_be_discussion_note? headers[:subject] = "Re: #{headers[:subject]}" if headers[:subject] |