diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/Text/Pandoc/Readers/MediaWiki.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/MediaWiki.hs b/src/Text/Pandoc/Readers/MediaWiki.hs index 6bcc4735e..27c8a6069 100644 --- a/src/Text/Pandoc/Readers/MediaWiki.hs +++ b/src/Text/Pandoc/Readers/MediaWiki.hs @@ -401,7 +401,10 @@ header = try $ do lev <- length <$> many1 (char '=') guard $ lev <= 6 contents <- trimInlines . mconcat <$> manyTill inline (count lev $ char '=') - attr <- modifyIdentifier <$> registerHeader nullAttr contents + opts <- mwOptions <$> getState + attr <- (if isEnabled Ext_gfm_auto_identifiers opts + then id + else modifyIdentifier) <$> registerHeader nullAttr contents return $ B.headerWith attr lev contents -- See #4731: |