lib/onebox/engine/pubmed_onebox.rb in onebox-1.4.2 vs lib/onebox/engine/pubmed_onebox.rb in onebox-1.4.3

- old
+ new

@@ -7,10 +7,10 @@ matches_regexp Regexp.new("^http(?:s)?://(?:(?:\\w)+\\.)?(www.ncbi.nlm.nih)\\.gov(?:/)?/pubmed/") private def get_xml - doc = Nokogiri::XML(open(@url + "?report=xml&format=text")) + doc = Nokogiri::XML(open(URI.join(@url, "?report=xml&format=text"))) pre = doc.xpath("//pre") Nokogiri::XML("<root>" + pre.text + "</root>") end def authors_of_xml(xml)