Commits

Ben Bangert  committed 2ef7c32

Fixing bug with regexp sub.

  • Participants
  • Parent commits ca21deb

Comments (0)

Files changed (1)

File webhelpers/html/converters.py

 """
 import re
 
-from webhelpers.html import HTML, literal
+from webhelpers.html import HTML, literal, lit_sub
 import webhelpers.textile as textile
 import webhelpers.markdown as _markdown
 
     """
     if text is None:
         return literal("")
-    text = _universal_newline_rx.sub("\n", text)
+    text = lit_sub(_universal_newline_rx, "\n", text)
     text = HTML(text).replace("\n", br)
     return text