Ticket #5663: markdown_1.6b.2.diff

File markdown_1.6b.2.diff, 996 bytes (added by Daniel Pope <dan@…>, 7 years ago)

Patch removing broken 1.6b codepath (fixed)

  • django/contrib/markup/templatetags/markup.py

     
    6666            else:
    6767                safe_mode = False
    6868
    69             # Unicode support only in markdown v1.7 or above. Version_info
    70             # exist only in markdown v1.6.2rc-2 or above.
    71             if getattr(markdown, "version_info", None) < (1,7):
    72                 return mark_safe(force_unicode(markdown.markdown(smart_str(value), extensions, safe_mode=safe_mode)))
    73             else:
    74                 return mark_safe(markdown.markdown(force_unicode(value), extensions, safe_mode=safe_mode))
     69            return mark_safe(markdown.markdown(force_unicode(value), extensions, safe_mode=safe_mode))
    7570        else:
    7671            return mark_safe(force_unicode(markdown.markdown(smart_str(value))))
    7772markdown.is_safe = True
Back to Top