mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-14 20:33:59 +02:00
committed by
Bjørn Erik Pedersen
parent
46ce1f191b
commit
2db43f841c
@@ -168,7 +168,7 @@ func highlight(fw hugio.FlexiWriter, code, lang string, attributes []attributes.
|
||||
lexer = chromalexers.Get(lang)
|
||||
}
|
||||
|
||||
if lexer == nil && (cfg.GuessSyntax && !cfg.NoHl) {
|
||||
if lexer == nil && cfg.GuessSyntax {
|
||||
lexer = lexers.Analyse(code)
|
||||
if lexer == nil {
|
||||
lexer = lexers.Fallback
|
||||
|
Reference in New Issue
Block a user