Skip to content

Commit

Permalink
fixes Nokogiri regression: tenderlove/nokogiri#620
Browse files Browse the repository at this point in the history
  • Loading branch information
rubiii committed Feb 17, 2012
1 parent ab160ce commit 6ec840b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/nori/parser/nokogiri.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ def characters(string)
end

def self.parse(xml)
return {} if xml.strip.empty?

document = Document.new
parser = ::Nokogiri::XML::SAX::Parser.new document
parser.parse xml
Expand Down

0 comments on commit 6ec840b

Please sign in to comment.