Rename for more idiomatic Ruby

This commit is contained in:
Thiago Arrais 2016-11-30 18:16:25 -03:00
parent 4ed41558d1
commit 91f0b91d6a
1 changed files with 3 additions and 3 deletions

View File

@ -12,7 +12,7 @@ module Jekyll
def group_by(input, property)
if groupable?(input)
groups = input.group_by { |item| item_property(item, property).to_s }
make_grouped_array(groups)
grouped_array(groups)
else
input
end
@ -34,7 +34,7 @@ module Jekyll
@context[variable] = item
parsed_expr.render(@context)
end
make_grouped_array(groups)
grouped_array(groups)
end
end
@ -49,7 +49,7 @@ module Jekyll
end
private
def make_grouped_array(groups)
def grouped_array(groups)
groups.each_with_object([]) do |item, array|
array << {
"name" => item.first,