diff options
Diffstat (limited to 'modules/markup')
-rw-r--r-- | modules/markup/markup.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/modules/markup/markup.go b/modules/markup/markup.go index 0ea4099600..dc43b533c0 100644 --- a/modules/markup/markup.go +++ b/modules/markup/markup.go @@ -15,6 +15,14 @@ import ( func Init() { getIssueFullPattern() NewSanitizer() + + // since setting maybe changed extensions, this will reload all parser extensions mapping + extParsers = make(map[string]Parser) + for _, parser := range parsers { + for _, ext := range parser.Extensions() { + extParsers[strings.ToLower(ext)] = parser + } + } } // Parser defines an interface for parsering markup file to HTML |