summaryrefslogtreecommitdiff
path: root/app/models/legacy_diff_discussion.rb
blob: 6515762c92d418d224ec164eb6ac9f85a29cb09d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# A discussion on merge request or commit diffs consisting of `LegacyDiffNote` notes.
# All new diff discussions are of the type `DiffDiscussion`, but any diff discussions created
# before the introduction of the new implementation still use `LegacyDiffDiscussion`.
class LegacyDiffDiscussion < Discussion
  include DiscussionOnDiff

  def legacy_diff_discussion?
    true
  end

  def potentially_resolvable?
    false
  end

  def collapsed?
    !active?
  end

  def reply_attributes
    super.merge(line_code: line_code)
  end
end