diff --git a/src/Text/Pandoc/Writers/FB2.hs b/src/Text/Pandoc/Writers/FB2.hs index 2401d7eee..20af67b62 100644 --- a/src/Text/Pandoc/Writers/FB2.hs +++ b/src/Text/Pandoc/Writers/FB2.hs @@ -85,7 +85,7 @@ pandocToFB2 :: PandocMonad m -> Pandoc -> FBM m String pandocToFB2 opts (Pandoc meta blocks) = do - modify (\s -> s { writerOptions = opts { writerOptions = opts } }) + modify (\s -> s { writerOptions = opts }) desc <- description meta fp <- frontpage meta secs <- renderSections 1 blocks diff --git a/src/Text/Pandoc/Writers/HTML.hs b/src/Text/Pandoc/Writers/HTML.hs index 4c8ccfe4a..b2b0865bf 100644 --- a/src/Text/Pandoc/Writers/HTML.hs +++ b/src/Text/Pandoc/Writers/HTML.hs @@ -115,7 +115,7 @@ writeHtml :: PandocMonad m => WriterOptions -> Pandoc -> m Html writeHtml opts d = do (body, context) <- evalStateT (pandocToHtml opts d) defaultWriterState return $ case writerTemplate opts of - Nothing -> renderHtml body + Nothing -> body Just tpl -> renderTemplate' tpl $ defField "body" (renderHtml body) context