diff options
author | Matthew Draper <matthew@trebex.net> | 2017-02-26 14:17:43 +1030 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-26 14:17:43 +1030 |
commit | 83f7f4f0aff116433b5be5fb21a3a1e8a24d8299 (patch) | |
tree | 916eecfbd0b5b72e32af376c7dfdebcae0716922 /activerecord/lib/active_record | |
parent | 0bd0c2886f0f74ae3af52c114b912ce5be3176f8 (diff) | |
parent | 08e781569aea7f0e084c169c70b452e337aa1b5f (diff) | |
download | rails-83f7f4f0aff116433b5be5fb21a3a1e8a24d8299.tar.gz rails-83f7f4f0aff116433b5be5fb21a3a1e8a24d8299.tar.bz2 rails-83f7f4f0aff116433b5be5fb21a3a1e8a24d8299.zip |
Merge pull request #28167 from kirs/deprecate-verify-args
Deprecate AbstractAdapter#verify! with arguments
Diffstat (limited to 'activerecord/lib/active_record')
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/abstract_adapter.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb b/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb index b31ce0a181..26eb70d7cd 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb @@ -439,6 +439,9 @@ module ActiveRecord # This is done under the hood by calling #active?. If the connection # is no longer active, then this method will reconnect to the database. def verify!(*ignored) + if ignored.size > 0 + ActiveSupport::Deprecation.warn("Passing arguments to #verify method of the connection has no affect and has been deprecated. Please remove all arguments from the #verify method call.") + end reconnect! unless active? end |