diff options
author | Rafael França <rafaelmfranca@gmail.com> | 2017-04-25 17:38:56 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-04-25 17:38:56 -0700 |
commit | c7ee244644903da5045c54f72e25a8ee6eb3bd68 (patch) | |
tree | a2359c8bc5d8afd7abd64ad5e9445b68ab1e3bc9 /activerecord/lib/active_record/relation/delegation.rb | |
parent | 550b5e0824cc1cbbe21a1554d1b3f347af08dd30 (diff) | |
parent | ca9ac310028d0009edf1fbf657541d2dea327535 (diff) | |
download | rails-c7ee244644903da5045c54f72e25a8ee6eb3bd68.tar.gz rails-c7ee244644903da5045c54f72e25a8ee6eb3bd68.tar.bz2 rails-c7ee244644903da5045c54f72e25a8ee6eb3bd68.zip |
Merge pull request #28831 from kamipo/respond_to_missing_should_be_private
`respond_to_missing?` should be private
Diffstat (limited to 'activerecord/lib/active_record/relation/delegation.rb')
-rw-r--r-- | activerecord/lib/active_record/relation/delegation.rb | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/activerecord/lib/active_record/relation/delegation.rb b/activerecord/lib/active_record/relation/delegation.rb index 50378f9d99..8b4dd25689 100644 --- a/activerecord/lib/active_record/relation/delegation.rb +++ b/activerecord/lib/active_record/relation/delegation.rb @@ -109,12 +109,10 @@ module ActiveRecord end end - def respond_to_missing?(method, include_private = false) - super || @klass.respond_to?(method, include_private) || - arel.respond_to?(method, include_private) - end - private + def respond_to_missing?(method, _) + super || @klass.respond_to?(method) || arel.respond_to?(method) + end def method_missing(method, *args, &block) if @klass.respond_to?(method) |