aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--activerecord/lib/active_record/associations/association_proxy.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/associations/association_proxy.rb b/activerecord/lib/active_record/associations/association_proxy.rb
index f2de788522..b752f1fdc0 100644
--- a/activerecord/lib/active_record/associations/association_proxy.rb
+++ b/activerecord/lib/active_record/associations/association_proxy.rb
@@ -185,9 +185,8 @@ module ActiveRecord
scope = target_klass.unscoped
scope = scope.create_with(creation_attributes)
scope = scope.apply_finder_options(@reflection.options.slice(:conditions, :readonly, :include))
- scope = scope.where(construct_owner_conditions)
scope = scope.select(select_value) if select_value = self.select_value
- scope
+ scope.where(construct_owner_conditions)
end
def select_value