aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc
diff options
context:
space:
mode:
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r--src/Text/Pandoc/Writers/Docbook.hs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Writers/Docbook.hs b/src/Text/Pandoc/Writers/Docbook.hs
index 398920839..affa0de04 100644
--- a/src/Text/Pandoc/Writers/Docbook.hs
+++ b/src/Text/Pandoc/Writers/Docbook.hs
@@ -201,6 +201,8 @@ blockToDocbook opts (Div (ident,classes,_) bs) = do
(l:_) | l `elem` admonitions -> do
let (mTitleBs, bodyBs) =
case bs of
+ -- Matches AST produced by the DocBook reader → Markdown writer → Markdown reader chain.
+ (Div (_,["title"],_) [Para ts] : rest) -> (Just (inlinesToDocbook opts ts), rest)
-- Matches AST produced by the Docbook reader.
(Div (_,["title"],_) ts : rest) -> (Just (blocksToDocbook opts ts), rest)
_ -> (Nothing, bs)