lib/approvals/writers/array_writer.rb in approvals-0.0.10 vs lib/approvals/writers/array_writer.rb in approvals-0.0.11

- old
+ new

@@ -1,14 +1,12 @@ module Approvals module Writers class ArrayWriter < TextWriter def format(data) - s = "" - data.each_with_index do |value, i| - s << "[#{i.inspect}] #{value.inspect}\n" - end - s + data.map.with_index do |value, i| + "[#{i.inspect}] #{value.inspect}\n" + end.join end end end end