Sha256: 836aea157cc8a74f37c92c3d3e02819af058f98f6d9ff7aec137658016f9a8ac
Contents?: true
Size: 758 Bytes
Versions: 14
Compression:
Stored size: 758 Bytes
Contents
# This migration comes from spree (originally 20131001013410) class RemoveUnusedCreditCardFields < ActiveRecord::Migration def up remove_column :spree_credit_cards, :start_month if column_exists?(:spree_credit_cards, :start_month) remove_column :spree_credit_cards, :start_year if column_exists?(:spree_credit_cards, :start_year) remove_column :spree_credit_cards, :issue_number if column_exists?(:spree_credit_cards, :issue_number) end def down add_column :spree_credit_cards, :start_month, :string add_column :spree_credit_cards, :start_year, :string add_column :spree_credit_cards, :issue_number, :string end def column_exists?(table, column) ActiveRecord::Base.connection.column_exists?(table, column) end end
Version data entries
14 entries across 14 versions & 7 rubygems