aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Writers/OPML.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Text/Pandoc/Writers/OPML.hs')
-rw-r--r--src/Text/Pandoc/Writers/OPML.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Text/Pandoc/Writers/OPML.hs b/src/Text/Pandoc/Writers/OPML.hs
index 5770c3c6f..20c2c5cbc 100644
--- a/src/Text/Pandoc/Writers/OPML.hs
+++ b/src/Text/Pandoc/Writers/OPML.hs
@@ -56,9 +56,9 @@ writeOPML opts (Pandoc meta blocks) =
meta'
main = render colwidth $ vcat (map (elementToOPML opts) elements)
context = defField "body" main metadata
- in if writerStandalone opts
- then renderTemplate' (writerTemplate opts) context
- else main
+ in case writerTemplate opts of
+ Nothing -> main
+ Just tpl -> renderTemplate' tpl context
writeHtmlInlines :: [Inline] -> String
writeHtmlInlines ils = trim $ writeHtmlString def