Skip to content

Commit

Permalink
trying to talk ci in to passing
Browse files Browse the repository at this point in the history
  • Loading branch information
orangewolf authored and dunn committed Oct 31, 2023
1 parent 1c64fcb commit 5ce53e0
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,12 @@ class Entry < ApplicationRecord

class ChangeImporterAndExporterToPolymorphic < ActiveRecord::Migration[5.1]
def change
remove_foreign_key :bulkrax_entries, column: :importer_id if foreign_key_exists?(:bulkrax_entries, column: :importer_id)
begin # deal with odd bug around foreign keys in ci
remove_foreign_key :bulkrax_entries, column: :importer_id if foreign_key_exists?(:bulkrax_entries, column: :importer_id)
rescue ArgumentError
# do nothing
end

remove_index :bulkrax_entries, :importer_id if index_exists?(:bulkrax_entries, :importer_id)
rename_column :bulkrax_entries, :importer_id, :importerexporter_id if column_exists?(:bulkrax_entries, :importer_id)
add_column :bulkrax_entries, :importerexporter_type, :string, after: :id, default: 'Bulkrax::Importer' unless column_exists?(:bulkrax_entries, :importerexporter_type)
Expand Down

0 comments on commit 5ce53e0

Please sign in to comment.