git.iko.soy/typeable/pandoc
on master help sign in
DocBook reader: Promote level 0 headers to 1 even if dbBook not set.
commit1c26f2c516bc8db1073dbe5f46bb14d512d1c7bb authorJohn MacFarlane <fiddlosopher@gmail.com> dateSat 12 May 2012, 12:24 (14 years ago) parent9d44dc3
1 file changed+1−1
src/Text/Pandoc/Readers/DocBook.hs+1−1
src/Text/Pandoc/Readers/DocBook.hs+1−1
@@ -809,7 +809,7 @@ parseBlock (Elem e) =
809809 isEntry x = named "entry" x || named "td" x || named "th" x
810810 parseRow = mapM (parseMixed plain . elContent) . filterChildren isEntry
811811 sect n = do isbook <- gets dbBook
812− let n' = if isbook then n + 1 else n
812+ let n' = if isbook || n == 0 then n + 1 else n
813813 headerText <- case filterChild (named "title") e of
814814 Just t -> getInlines t
815815 Nothing -> return mempty