Skip to content
Snippets Groups Projects

Don't parse Rinku returned value to DocFragment when didn't change original html string.

Merged Paco Guzman requested to merge 18593-avoid-parse_html-when-rinku-didnt-do-anything into master
2 unresolved threads
3 files
+ 23
0
Compare changes
  • Side-by-side
  • Inline
Files
3
@@ -56,6 +56,8 @@ def rinku_parse
# period (e.g., http://localhost:3000/)
rinku = Rinku.auto_link(html, :urls, options, IGNORE_PARENTS.to_a, 1)
return if rinku == html
# Rinku returns a String, so parse it back to a Nokogiri::XML::Document
# for further processing.
@doc = parse_html(rinku)
Loading