Skip to content
This repository has been archived by the owner on Dec 24, 2019. It is now read-only.

Commit

Permalink
Fix #to_list ext after squash -> compact change.
Browse files Browse the repository at this point in the history
  • Loading branch information
benhoskings committed May 3, 2017
1 parent fea4e0a commit 0d1e3c0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/babushka/core_patches/array.rb
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ def to_list(opts = {})
[
items[0..-2].compact.join(', '),
items.last
].compact.join("#{',' if opts[:oxford]} #{opts[:conj] || 'and'} ")
].reject(&:blank?).join("#{',' if opts[:oxford]} #{opts[:conj] || 'and'} ")
end

# If the final element of the array is a +Hash+, it's removed from this array
Expand Down

0 comments on commit 0d1e3c0

Please sign in to comment.