diff options
author | hhoopes <heidih@gmail.com> | 2016-08-22 23:36:30 -0600 |
---|---|---|
committer | Sean McGivern <sean@gitlab.com> | 2016-11-25 15:23:49 +0000 |
commit | 24070bac45134c915c13d3e94723a44f59ab4e3a (patch) | |
tree | 59ba105e715d8a2f65547ca1f03e9ba231b48ff4 /app/mailers/emails | |
parent | 38ed96e9b1a47dca5aa2590fa9b0ade908337435 (diff) | |
download | gitlab-ce-24070bac45134c915c13d3e94723a44f59ab4e3a.tar.gz |
Add new template to handle both commit & mr notes
Currently comments on commits and merge requests do not require merge request- or commit-specific information, but can use the same template. Rather than change the method which calls the template, I opted to keep the templates separate and create a new template to highlight their identicality, while preserving the option to distinguish them from each other in the future.
Also removed some of the inconsistencies between text and html email versions.
Still needed is a text-only version of git diffs and testing.
Diffstat (limited to 'app/mailers/emails')
-rw-r--r-- | app/mailers/emails/notes.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/app/mailers/emails/notes.rb b/app/mailers/emails/notes.rb index 96116e916dd..0d20c9092c4 100644 --- a/app/mailers/emails/notes.rb +++ b/app/mailers/emails/notes.rb @@ -4,6 +4,7 @@ module Emails setup_note_mail(note_id, recipient_id) @commit = @note.noteable + @discussion = @note.to_discussion if @note.diff_note? @target_url = namespace_project_commit_url(*note_target_url_options) mail_answer_thread(@commit, @@ -24,6 +25,7 @@ module Emails setup_note_mail(note_id, recipient_id) @merge_request = @note.noteable + @discussion = @note.to_discussion if @note.diff_note? @target_url = namespace_project_merge_request_url(*note_target_url_options) mail_answer_thread(@merge_request, note_thread_options(recipient_id)) end |