discourse/plugins/chat/db/migrate/20210823160357_create_chat_...

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

16 lines
460 B
Ruby
Raw Normal View History

# frozen_string_literal: true
class CreateChatWebhookEvents < ActiveRecord::Migration[6.1]
def change
create_table :chat_webhook_events do |t|
t.integer :chat_message_id, null: false
t.integer :incoming_chat_webhook_id, null: false
t.timestamps
end
add_index :chat_webhook_events,
%i[chat_message_id incoming_chat_webhook_id],
unique: true,
name: "chat_webhook_events_index"
end
end