# db/migrate/20230427131800_create_chats.rb class CreateChats < ActiveRecord::Migration[7.0] def change create_table :chats do |t| t.belongs_to :user, null: false, foreign_key: true t.timestamps end end end