diff options
author | John MacFarlane <jgm@berkeley.edu> | 2013-11-22 23:40:46 -0800 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2013-11-22 23:40:46 -0800 |
commit | 56277bacea73818a7541b60987e5bc877782baab (patch) | |
tree | b536ff2c03488c940354ed62515ee25760e5c7df /src/Text | |
parent | 4321a09b7fa5b52e72aef4fa637392d7da4eb808 (diff) | |
download | pandoc-56277bacea73818a7541b60987e5bc877782baab.tar.gz |
EPUB writer: Don't include node for cover.xhtml if no cover!
Diffstat (limited to 'src/Text')
-rw-r--r-- | src/Text/Pandoc/Writers/EPUB.hs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Text/Pandoc/Writers/EPUB.hs b/src/Text/Pandoc/Writers/EPUB.hs index 98f043cd8..ef4c7be23 100644 --- a/src/Text/Pandoc/Writers/EPUB.hs +++ b/src/Text/Pandoc/Writers/EPUB.hs @@ -267,8 +267,9 @@ writeEPUB opts doc@(Pandoc meta _) = do , unode "guide" $ [ unode "reference" ! [("type","toc"),("title",plainTitle),("href","nav.xhtml")] $ () - , unode "reference" ! - [("type","cover"),("title","Cover"),("href","cover.xhtml")] $ () + ] ++ + [ unode "reference" ! + [("type","cover"),("title","Cover"),("href","cover.xhtml")] $ () | mbCoverImage /= Nothing ] ] let contentsEntry = mkEntry "content.opf" contentsData |