diff options
author | Ryuta Kamizono <kamipo@gmail.com> | 2017-03-05 20:28:03 +0900 |
---|---|---|
committer | Ryuta Kamizono <kamipo@gmail.com> | 2017-03-05 20:28:03 +0900 |
commit | 60440a68b13a5408cd9c492cc2eaed2e68f95bd7 (patch) | |
tree | c12f4de2ef8543e0c4beda06fc4f74f6f016b7d3 /activerecord/lib/active_record/connection_adapters | |
parent | 12038f6505cdbcdbea861c7ae5f272e918100e13 (diff) | |
download | rails-60440a68b13a5408cd9c492cc2eaed2e68f95bd7.tar.gz rails-60440a68b13a5408cd9c492cc2eaed2e68f95bd7.tar.bz2 rails-60440a68b13a5408cd9c492cc2eaed2e68f95bd7.zip |
Remove useless `Migrator.schema_migrations_table_name`
Simply use `SchemaMigration.table_name` instead.
Diffstat (limited to 'activerecord/lib/active_record/connection_adapters')
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb index c9dd915e98..cbb93e0ffe 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb @@ -996,7 +996,7 @@ module ActiveRecord end def insert_versions_sql(versions) # :nodoc: - sm_table = quote_table_name(ActiveRecord::Migrator.schema_migrations_table_name) + sm_table = quote_table_name(ActiveRecord::SchemaMigration.table_name) if versions.is_a?(Array) sql = "INSERT INTO #{sm_table} (version) VALUES\n" @@ -1025,7 +1025,7 @@ module ActiveRecord def assume_migrated_upto_version(version, migrations_paths) migrations_paths = Array(migrations_paths) version = version.to_i - sm_table = quote_table_name(ActiveRecord::Migrator.schema_migrations_table_name) + sm_table = quote_table_name(ActiveRecord::SchemaMigration.table_name) migrated = select_values("SELECT version FROM #{sm_table}").map(&:to_i) versions = ActiveRecord::Migrator.migration_files(migrations_paths).map do |file| |