mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Fix deprecation warning of ActiveRecord::Migrator.migrations_path=
`ActiveRecord::Migrator.migrations_path=` was deprecated in #31727. This commit fixes: - `ActiveRecord::Migrator.migrations_path=` is deprecated, but not `ActiveRecord::Migrator.migrations_paths=` - Adds missing space The warning including this commit: ``` DEPRECATION WARNING: `ActiveRecord::Migrator.migrations_path=` is now deprecated and will be removed in Rails 6.0. You can set the `migrations_paths` on the `connection` instead through the `database.yml`. ``` Since it was deprecated in Rails 5.2 we should backport it to the `5-2-stable` branch. Related to #31727
This commit is contained in:
parent
fca8da18ac
commit
d48a9ebe9a
1 changed files with 1 additions and 1 deletions
|
@ -1169,7 +1169,7 @@ module ActiveRecord
|
|||
|
||||
def migrations_path=(path)
|
||||
ActiveSupport::Deprecation.warn \
|
||||
"ActiveRecord::Migrator.migrations_paths= is now deprecated and will be removed in Rails 6.0." \
|
||||
"`ActiveRecord::Migrator.migrations_path=` is now deprecated and will be removed in Rails 6.0. " \
|
||||
"You can set the `migrations_paths` on the `connection` instead through the `database.yml`."
|
||||
self.migrations_paths = [path]
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue