lib/onebox/helpers.rb in onebox-1.8.23 vs lib/onebox/helpers.rb in onebox-1.8.24

- old
+ new

@@ -22,10 +22,10 @@ return {} unless doc og = {} doc.css('meta').each do |m| - if (m["property"] && m["property"][/^og:(.+)$/i]) || (m["name"] && m["name"][/^og:(.+)$/i]) + if (m["property"] && m["property"][/^(?:og|article):(.+)$/i]) || (m["name"] && m["name"][/^(?:og|article):(.+)$/i]) value = (m["content"] || m["value"]).to_s og[$1.tr('-:', '_').to_sym] ||= value unless Onebox::Helpers::blank?(value) end end