glitchier-soc/db/migrate/20170624134742_add_description_to_session_activations.rb

12 lines
350 B
Ruby
Raw Normal View History

# frozen_string_literal: true
class AddDescriptionToSessionActivations < ActiveRecord::Migration[5.1]
def change
change_table(:session_activations, bulk: true) do |t|
t.column :user_agent, :string, null: false, default: ''
t.column :ip, :inet
end
add_foreign_key :session_activations, :users, on_delete: :cascade
end
end