summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHeinrich Lee Yu <heinrich@gitlab.com>2019-03-21 11:56:21 +0800
committerHeinrich Lee Yu <heinrich@gitlab.com>2019-03-21 11:56:21 +0800
commit383efe377bb2b2da0b020b92033d41060a1f1d5b (patch)
treebdbe197211aeda6c7446952bf789267f467b4556
parentfbc49fa332fb2302b13a556af02efcc18b3e004d (diff)
downloadgitlab-ce-55268-exclude-system-notes-from-commits-in-mr-grouping.tar.gz
Fix system notes on commits rendering in MR55268-exclude-system-notes-from-commits-in-mr-grouping
System notes are now rendered individually instead of being included with other individual notes grouped into one `OutOfContextDiscussion`.
-rw-r--r--app/models/note.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/note.rb b/app/models/note.rb
index 2c9980b1a0d..7f6d5439121 100644
--- a/app/models/note.rb
+++ b/app/models/note.rb
@@ -358,7 +358,7 @@ class Note < ActiveRecord::Base
# When commit notes are rendered on an MR's Discussion page, they are
# displayed in one discussion instead of individually.
# See also `#discussion_id` and `Discussion.override_discussion_id`.
- if noteable && noteable != self.noteable
+ if noteable && noteable != self.noteable && !system?
OutOfContextDiscussion
else
IndividualNoteDiscussion