1
0

20210908220918_create_status_edits.rb 501 B

123456789101112131415
  1. # frozen_string_literal: true
  2. class CreateStatusEdits < ActiveRecord::Migration[6.1]
  3. def change
  4. create_table :status_edits do |t|
  5. t.belongs_to :status, null: false, foreign_key: { on_delete: :cascade }
  6. t.belongs_to :account, null: true, foreign_key: { on_delete: :nullify }
  7. t.text :text, null: false, default: ''
  8. t.text :spoiler_text, null: false, default: ''
  9. t.boolean :media_attachments_changed, null: false, default: false
  10. t.timestamps
  11. end
  12. end
  13. end