1 # frozen_string_literal: true
3 # == Schema Information
5 # Table name: issue_comments
7 # id :integer not null, primary key
8 # issue_id :integer not null
9 # user_id :integer not null
11 # created_at :datetime not null
12 # updated_at :datetime not null
16 # index_issue_comments_on_issue_id (issue_id)
17 # index_issue_comments_on_user_id (user_id)
21 # issue_comments_issue_id_fkey (issue_id => issues.id)
22 # issue_comments_user_id_fkey (user_id => users.id)
25 class IssueComment < ApplicationRecord
29 validates :body, :presence => true, :characters => true
32 RichText.new("markdown", self[:body])