diff options
author | John MacFarlane <jgm@berkeley.edu> | 2014-01-06 10:17:31 -0800 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2014-01-06 10:17:31 -0800 |
commit | 2dd6d892fa310135cece1d8e6d6bac7b538f4e76 (patch) | |
tree | 98abfcdac6d539a9af6ed9431e16ad8413688577 /src/Text | |
parent | 3dd1b1f73ac0abf54288573d886708c63d1797dd (diff) | |
download | pandoc-2dd6d892fa310135cece1d8e6d6bac7b538f4e76.tar.gz |
HTML writer: Omit footnotes from TOC entries.
Otherwise we get doubled footnotes when headers have notes!
Diffstat (limited to 'src/Text')
-rw-r--r-- | src/Text/Pandoc/Writers/HTML.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/HTML.hs b/src/Text/Pandoc/Writers/HTML.hs index c8a7e802b..805bb57f1 100644 --- a/src/Text/Pandoc/Writers/HTML.hs +++ b/src/Text/Pandoc/Writers/HTML.hs @@ -749,7 +749,9 @@ inlineToHtml opts inline = else [A.title $ toValue tit]) return $ foldl (!) H5.embed attributes -- note: null title included, as in Markdown.pl - (Note contents) -> do + (Note contents) + | writerIgnoreNotes opts -> return mempty + | otherwise -> do st <- get let notes = stNotes st let number = (length notes) + 1 |