@@ -99,7 +99,7 @@ tableOfContents opts headers ids =
9999 let opts' = opts { writerIgnoreNotes = True }
100100 contentsTree = hierarchicalize headers
101101 contents = evalState (mapM (elementToListItem opts') contentsTree)
102− (WriterState {stNotes= [], stIds = [], stHead = []})
102+ (WriterState {stNotes= [], stIds = ids, stHead = []})
103103 in thediv ! [identifier "toc"] $ unordList contents
104104
105105-- | Converts an Element to a list item for a table of contents,