Skip to content

Commit

Permalink
Merge pull request #294 from samvera/index_name_exists_rails_6
Browse files Browse the repository at this point in the history
use new index_name_exists? method signature if rails6 too
  • Loading branch information
elrayle committed Nov 22, 2019
2 parents 941dec5 + 0e61bc5 commit 639003c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/qa/authorities/local/mysql_table_based_authority.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def search(q)

def self.index_name_exists?
conn = ActiveRecord::Base.connection
if ActiveRecord::VERSION::MAJOR >= 5 && ActiveRecord::VERSION::MINOR >= 1
if (ActiveRecord::VERSION::MAJOR == 5 && ActiveRecord::VERSION::MINOR >= 1) || ActiveRecord::VERSION::MAJOR >= 6
conn.index_name_exists?(table_name, table_index).blank?
else
conn.index_name_exists?(table_name, table_index, :default).blank?
Expand Down

0 comments on commit 639003c

Please sign in to comment.