discourse/plugins/chat/app/models/chat/message_revision.rb
Jarek Radosz 378bed012c
DEV: Improve separation of core and plugin CI (#33583)
1. Use separate caches for plugins and core
2. Don't load plugins in non-plugin jobs
3. Propagate LOAD_PLUGINS to all steps
4. Check annotations of plugin models
5. Update outdated annotations
2025-07-14 14:28:30 +02:00

31 lines
868 B
Ruby

# frozen_string_literal: true
module Chat
class MessageRevision < ActiveRecord::Base
self.table_name = "chat_message_revisions"
validates :old_message, length: { maximum: 50_000 }
validates :new_message, length: { maximum: 50_000 }
belongs_to :chat_message, class_name: "Chat::Message"
belongs_to :user
end
end
# == Schema Information
#
# Table name: chat_message_revisions
#
# id :bigint not null, primary key
# chat_message_id :bigint
# old_message :text not null
# new_message :text not null
# created_at :datetime not null
# updated_at :datetime not null
# user_id :integer not null
#
# Indexes
#
# index_chat_message_revisions_on_chat_message_id (chat_message_id)
# index_chat_message_revisions_on_user_id (user_id)
#