lib/bolognese/utils.rb in bolognese-0.9.14 vs lib/bolognese/utils.rb in bolognese-0.9.15
- old
+ new
@@ -384,10 +384,11 @@
def to_schema_org(element)
Array.wrap(element).map do |a|
a["@type"] = a["type"]
a["@id"] = a["id"]
- a.except("type", "id").compact
+ a["name"] = a["title"] if a["title"].present?
+ a.except("type", "id", "title").compact
end.unwrap
end
def from_schema_org(element)
Array.wrap(element).map do |a|