Markdown reader: Don't generate blank title, author, date elements.
This commit is contained in:
parent
caa89efc32
commit
5a5a252216
1 changed files with 3 additions and 3 deletions
|
@ -221,9 +221,9 @@ pandocTitleBlock = try $ do
|
|||
title' <- title
|
||||
author' <- author
|
||||
date' <- date
|
||||
return $ B.setMeta "title" title'
|
||||
. B.setMeta "author" author'
|
||||
. B.setMeta "date" date'
|
||||
return $ if B.isNull title' then id else B.setMeta "title" title'
|
||||
. if null author' then id else B.setMeta "author" author'
|
||||
. if B.isNull date' then id else B.setMeta "date" date'
|
||||
|
||||
yamlTitleBlock :: MarkdownParser (F (Pandoc -> Pandoc))
|
||||
yamlTitleBlock = try $ do
|
||||
|
|
Loading…
Reference in a new issue