lib/bolognese/readers/schema_org_reader.rb in bolognese-1.9.7 vs lib/bolognese/readers/schema_org_reader.rb in bolognese-1.9.8
- old
+ new
@@ -24,11 +24,11 @@
}
def get_schema_org(id: nil, **options)
return { "string" => nil, "state" => "not_found" } unless id.present?
- id = normalize_id(id)
- response = Maremma.get(id)
+ url = normalize_id(id)
+ response = Maremma.get(url)
doc = Nokogiri::XML(response.body.fetch("data", nil), nil, 'UTF-8')
# workaround for xhtml documents
nodeset = doc.css("script")
string = nodeset.find { |element| element["type"] == "application/ld+json" }