DocBook reader: Promote level 0 headers to 1 even if dbBook not set.

This commit is contained in:
John MacFarlane
2012-05-12 12:24:26 -07:00
parent 9d44dc3887
commit 1c26f2c516
+1 -1
View File
@@ -809,7 +809,7 @@ parseBlock (Elem e) =
isEntry x = named "entry" x || named "td" x || named "th" x
parseRow = mapM (parseMixed plain . elContent) . filterChildren isEntry
sect n = do isbook <- gets dbBook
let n' = if isbook then n + 1 else n
let n' = if isbook || n == 0 then n + 1 else n
headerText <- case filterChild (named "title") e of
Just t -> getInlines t
Nothing -> return mempty