diff options
author | Douwe Maan <douwe@selenight.nl> | 2017-04-04 18:20:08 -0500 |
---|---|---|
committer | Luke "Jared" Bennett <lbennett@gitlab.com> | 2017-04-05 17:44:14 +0100 |
commit | 077a1571677fdf29cb4ed418b15b816bab311372 (patch) | |
tree | 46041bb40effa758e4c2fef2974b7bf560e4654b /app/models/discussion.rb | |
parent | 3ff708f723a8c3c911c5a19e6239ded1cf2b0bce (diff) | |
download | gitlab-ce-077a1571677fdf29cb4ed418b15b816bab311372.tar.gz |
Add line breaks in long comments
Diffstat (limited to 'app/models/discussion.rb')
-rw-r--r-- | app/models/discussion.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/app/models/discussion.rb b/app/models/discussion.rb index 22130b8a508..8268a140403 100644 --- a/app/models/discussion.rb +++ b/app/models/discussion.rb @@ -37,15 +37,17 @@ class Discussion [:discussion, note.noteable_type.try(:underscore), noteable_id] end - # To turn a list of notes into a list of discussions, they are grouped by discussion ID. # When notes on a commit are displayed in context of a merge request that contains that commit, # these notes are to be displayed as if they were part of one discussion, even though they were actually # individual notes on the commit with different discussion IDs, so that it's clear that these are not # notes on the merge request itself. - # To get these out-of-context notes to end up in the same discussion, we need to get them to return the same + # + # To turn a list of notes into a list of discussions, they are grouped by discussion ID, so to + # get these out-of-context notes to end up in the same discussion, we need to get them to return the same # `discussion_id` when this grouping happens. To enable this, `Note#discussion_id` calls out # to the `override_discussion_id` method on the appropriate `Discussion` subclass, as determined by # the `discussion_class` method on `Note` or a subclass of `Note`. + # # If no override is necessary, return `nil`. # For the case described above, see `OutOfContextDiscussion.override_discussion_id`. def self.override_discussion_id(note) |