aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Text/Pandoc/Writers/Markdown.hs2
-rw-r--r--test/command/6133.md12
2 files changed, 13 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/Markdown.hs b/src/Text/Pandoc/Writers/Markdown.hs
index 74662083a..bce1c37fa 100644
--- a/src/Text/Pandoc/Writers/Markdown.hs
+++ b/src/Text/Pandoc/Writers/Markdown.hs
@@ -125,7 +125,7 @@ mmdTitleBlock (Context hashmap) =
(k', SimpleVal x)
| isEmpty x -> empty
| otherwise -> k' <> ":" <> space <>
- nest 2 (chomp (removeBlankLines x))
+ nest 2 (removeBlankLines (chomp x))
_ -> empty
removeBlankLines BlankLines{} = cr <> text "." <> cr
removeBlankLines (Concat x y) = removeBlankLines x <>
diff --git a/test/command/6133.md b/test/command/6133.md
new file mode 100644
index 000000000..f260356c2
--- /dev/null
+++ b/test/command/6133.md
@@ -0,0 +1,12 @@
+```
+% pandoc -f markdown_mmd -t markdown_mmd -s
+author: Author
+title: Title
+
+Some text
+^D
+author: Author
+title: Title
+
+Some text
+```