Welcome to mirror list, hosted at ThFree Co, Russian Federation.

active_record_migration.rb « initializers « config - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 04c06be78340356fd09afab7960409563a762d87 (plain)
1
2
3
4
5
6
7
8
9
10
require 'active_record/migration'

module ActiveRecord
  class Migration
    # data_source_exists? is not available in 4.2.10, table_exists deprecated in 5.0
    def table_exists?(table_name)
      ActiveRecord::Base.connection.data_source_exists?(table_name)
    end
  end
end