From d4a7cf76eb3c95bda40b14e1af8fbb21a325e30b 2014-03-05 22:37:38 From: Jonathan Frederic Date: 2014-03-05 22:37:38 Subject: [PATCH] Switch if/else order --- diff --git a/IPython/nbconvert/filters/markdown.py b/IPython/nbconvert/filters/markdown.py index 931beb6..e550565 100755 --- a/IPython/nbconvert/filters/markdown.py +++ b/IPython/nbconvert/filters/markdown.py @@ -77,10 +77,10 @@ def markdown2html(source): warnings.warn( "Node.js 0.9.12 or later wasn't found.\n" + "Nbconvert will try to use Pandoc instead.") _node = False - if not _node: - return markdown2html_pandoc(source) - else: + if _node: return markdown2html_marked(source) + else: + return markdown2html_pandoc(source) def markdown2html_pandoc(source): """Convert a markdown string to HTML via pandoc"""