class RenameUserIdAndAddColumnsIntoPurchase < ActiveRecord::Migration
  def change
  	rename_column :purchases, :userid, :user_id if column_exists?(:purchases, :userid)
  	add_column :purchases, :status, :integer, null: false, default: 0 if !column_exists?(:purchases, :status)
  end
end
