diff options
author | Jon Leighton <j@jonathanleighton.com> | 2011-09-07 09:26:02 +0100 |
---|---|---|
committer | Jon Leighton <j@jonathanleighton.com> | 2011-09-07 09:27:41 +0100 |
commit | 143769051bcf5b3a7600744be2d8db6e9c859288 (patch) | |
tree | 220be95b653bf31119a709b6974cac2ecdad02f8 /activerecord/lib/active_record/associations | |
parent | db8d54ebf5102d2f30c0c332ea852ad284702ef3 (diff) | |
download | rails-143769051bcf5b3a7600744be2d8db6e9c859288.tar.gz rails-143769051bcf5b3a7600744be2d8db6e9c859288.tar.bz2 rails-143769051bcf5b3a7600744be2d8db6e9c859288.zip |
Don't include any of includes, preload, joins, eager_load in the through association scope.
Diffstat (limited to 'activerecord/lib/active_record/associations')
-rw-r--r-- | activerecord/lib/active_record/associations/through_association.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/associations/through_association.rb b/activerecord/lib/active_record/associations/through_association.rb index b010b5e9ef..b347a94978 100644 --- a/activerecord/lib/active_record/associations/through_association.rb +++ b/activerecord/lib/active_record/associations/through_association.rb @@ -16,7 +16,7 @@ module ActiveRecord chain[1..-1].each do |reflection| scope = scope.merge( reflection.klass.scoped.with_default_scope. - except(:select, :create_with, :includes, :preload) + except(:select, :create_with, :includes, :preload, :joins, :eager_load) ) end scope |