fix: fallback to syntax hl if treesitter fails (#1249)

This commit is contained in:
fdschmidt93
2021-09-17 00:07:54 +02:00
committed by GitHub
parent 7c5b846f6f
commit 5a020a8859

View File

@@ -74,7 +74,7 @@ utils.highlighter = function(bufnr, ft, opts)
if ts_highlighting then if ts_highlighting then
ts_success = utils.ts_highlighter(bufnr, ft) ts_success = utils.ts_highlighter(bufnr, ft)
end end
if not (ts_highlighting or ts_success) then if not ts_highlighting or ts_success == false then
utils.regex_highlighter(bufnr, ft) utils.regex_highlighter(bufnr, ft)
end end
end end