Fix checking method for empty pandoc path option

This commit is contained in:
KoharaKazuya 2015-04-16 07:45:45 +09:00
parent 2fe815e47c
commit 895515f6bd
1 changed files with 4 additions and 4 deletions

View File

@ -10,12 +10,12 @@ getCmd = (inputPath, outputPath, options, cb) ->
pandocPath = options.pandoc_path # jshint ignore: line
yamlFrontMatter = options.yaml_front_matter # jshint ignore: line
cmd = ""
if pandocPath?
# Use absolute path
cmd = pandocPath + optionsStr
else
if not pandocPath
# Use command available in $PATH
cmd = "pandoc" + optionsStr
else
# Use absolute path
cmd = pandocPath + optionsStr
if yamlFrontMatter?
# console.log("YAML Front Matter!")