aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
diff options
context:
space:
mode:
authorप्रथमेश Sonpatki <csonpatki@gmail.com>2016-01-09 10:53:04 +0530
committerप्रथमेश Sonpatki <csonpatki@gmail.com>2016-01-09 10:53:04 +0530
commita7a2bc0f66dd934ace716891cfcc422e2087ffeb (patch)
tree751d6de15298f98ceda0bd24a4141994740db361 /activerecord
parent37dadb0dc93076d8c4343f52a29edc3adc45b6f1 (diff)
parent16bf90364e754f40de921ec0ce2f88d1ec7645d9 (diff)
downloadrails-a7a2bc0f66dd934ace716891cfcc422e2087ffeb.tar.gz
rails-a7a2bc0f66dd934ace716891cfcc422e2087ffeb.tar.bz2
rails-a7a2bc0f66dd934ace716891cfcc422e2087ffeb.zip
Merge pull request #22986 from yui-knk/fix_automatic_inverse_of_comment
[ci skip] `automatic_inverse_of` returns `false` not `nil` (document …
Diffstat (limited to 'activerecord')
-rw-r--r--activerecord/lib/active_record/reflection.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/reflection.rb b/activerecord/lib/active_record/reflection.rb
index a549b28f16..37e18626b5 100644
--- a/activerecord/lib/active_record/reflection.rb
+++ b/activerecord/lib/active_record/reflection.rb
@@ -545,7 +545,7 @@ module ActiveRecord
end
end
- # returns either nil or the inverse association name that it finds.
+ # returns either false or the inverse association name that it finds.
def automatic_inverse_of
if can_find_inverse_of_automatically?(self)
inverse_name = ActiveSupport::Inflector.underscore(options[:as] || active_record.name.demodulize).to_sym