fix: dont convert from md if html

This commit is contained in:
Gavin D'souza 2020-05-20 13:18:19 +05:30
parent c8aed039bd
commit f3ccdd9ebc

View file

@ -481,7 +481,7 @@ def watch(path, handler=None, debug=True):
observer.join()
def markdown(text, sanitize=True, linkify=True):
html = frappe.utils.md_to_html(text)
html = text if is_html(text) else frappe.utils.md_to_html(text)
if sanitize:
html = html.replace("<!-- markdown -->", "")