Permalink
Browse files

only flatten one side

  • Loading branch information...
1 parent 7085aae commit 0aa6872dc55fcffb892ef066f869b6f9046b6943 @tenderlove tenderlove committed Jul 23, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/associations/builder/association.rb
View
2 activerecord/lib/active_record/associations/builder/association.rb
@@ -66,7 +66,7 @@ def macro
end
def valid_options
- (Association.valid_options + Association.extensions.map(&:valid_options)).flatten
+ Association.valid_options + Association.extensions.map(&:valid_options).flatten
end
def validate_options

1 comment on commit 0aa6872

@Empact

#flat_map would work here as well.

Please sign in to comment.