parent
21c7f2298a
commit
99cc12cc0a
|
@ -77,9 +77,8 @@ module Jekyll
|
||||||
end
|
end
|
||||||
|
|
||||||
def populate_categories
|
def populate_categories
|
||||||
if categories.empty?
|
categories_from_data = Utils.pluralized_array_from_hash(data, 'category', 'categories')
|
||||||
self.categories = Utils.pluralized_array_from_hash(data, 'category', 'categories').map {|c| c.to_s.downcase}
|
self.categories = (Array(categories) + categories_from_data).map {|c| c.to_s.downcase}
|
||||||
end
|
|
||||||
categories.flatten!
|
categories.flatten!
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue