aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2010-09-21 15:23:39 -0700
committerAaron Patterson <aaron.patterson@gmail.com>2010-09-21 15:25:09 -0700
commit50041e563a6a6e7ebe234c542935fb6fce4935e8 (patch)
tree79ae9e6f6d4d4e5348506fd4928f5d2a454f46d4 /activerecord/lib
parentfdd537e7f929f46a56d81a7a8a037489cd2e68fb (diff)
downloadrails-50041e563a6a6e7ebe234c542935fb6fce4935e8.tar.gz
rails-50041e563a6a6e7ebe234c542935fb6fce4935e8.tar.bz2
rails-50041e563a6a6e7ebe234c542935fb6fce4935e8.zip
this reject can be replaced with compact
Diffstat (limited to 'activerecord/lib')
-rw-r--r--activerecord/lib/active_record/associations.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/associations.rb b/activerecord/lib/active_record/associations.rb
index ae822c3080..79f8ce346d 100644
--- a/activerecord/lib/active_record/associations.rb
+++ b/activerecord/lib/active_record/associations.rb
@@ -2243,7 +2243,7 @@ module ActiveRecord
end
[
- [parent_table[parent.primary_key].eq(join_table[jt_foreign_key]), jt_as_extra, jt_source_extra, jt_sti_extra].reject{|x| x.blank? },
+ [parent_table[parent.primary_key].eq(join_table[jt_foreign_key]), jt_as_extra, jt_source_extra, jt_sti_extra].compact,
aliased_table[first_key].eq(join_table[second_key])
]
elsif reflection.options[:as]