提交 b54ef7eb 编写于 作者: Y Yves Senn

Revert "Merge pull request #11299 from arunagw/disable_implicit_join_references_removed"

`disable_implicit_join_references=` was only deprecated on `master`,
not with rails 4.0. We can remove it after 4.1

This reverts commit 3c719ead, reversing
changes made to d5c3bf97.
上级 5ade0ddf
* Remove deprecated `ActiveRecord::Base.disable_implicit_join_references=`.
*Arun Agrawal*
* Remove deprecated nil-passing to the following `SchemaCache` methods:
`primary_keys`, `tables`, `columns` and `columns_hash`.
......
......@@ -69,6 +69,11 @@ module Core
mattr_accessor :timestamped_migrations, instance_writer: false
self.timestamped_migrations = true
def self.disable_implicit_join_references=(value)
ActiveSupport::Deprecation.warn("Implicit join references were removed with Rails 4.1." \
"Make sure to remove this configuration because it does nothing.")
end
class_attribute :default_connection_handler, instance_writer: false
def self.connection_handler
......
......@@ -1216,6 +1216,12 @@ def test_primary_key
assert_equal "id", Post.all.primary_key
end
def test_disable_implicit_join_references_is_deprecated
assert_deprecated do
ActiveRecord::Base.disable_implicit_join_references = true
end
end
def test_ordering_with_extra_spaces
assert_equal authors(:david), Author.order('id DESC , name DESC').last
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册