gitlab-org--gitlab-foss/app/models/individual_note_discussion.rb

18 lines
405 B
Ruby
Raw Normal View History

2017-03-31 03:06:09 +00:00
# A discussion to wrap a single `Note` note on the root of an issue, merge request,
2017-04-04 22:27:23 +00:00
# commit, or snippet, that is not displayed as a discussion.
#
# A discussion of this type is never resolvable.
class IndividualNoteDiscussion < Discussion
def self.note_class
Note
end
2017-03-17 19:25:52 +00:00
def individual_note?
true
end
def reply_attributes
super.tap { |attrs| attrs.delete(:discussion_id) }
end
end