class CreateNotes < ActiveRecord::Migration - CreateNotes has no descriptive comment
def change - CreateNotes#change has approx 6 statements
create_table :notes do |t| -
- CreateNotes#change has the variable name 't'
t.references :petition
t.text :details
t.timestamps null: false
end
add_index :notes, :petition_id, unique: true
add_foreign_key :notes, :petitions, on_delete: :cascade
end
end