diff options
Diffstat (limited to 'lib/arel/algebra')
-rw-r--r-- | lib/arel/algebra/relations/row.rb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/arel/algebra/relations/row.rb b/lib/arel/algebra/relations/row.rb index f303dcd8d1..84f19e372f 100644 --- a/lib/arel/algebra/relations/row.rb +++ b/lib/arel/algebra/relations/row.rb @@ -12,10 +12,9 @@ module Arel end def slice(*attributes) - Row.new(relation, attributes.inject([]) do |cheese, attribute| + Row.new(relation, attributes.map do |attribute| # FIXME TESTME method chaining - cheese << tuple[relation.relation.position_of(attribute)] - cheese + tuple[relation.relation.position_of(attribute)] end) end |