apply bfredl suggestion

This commit is contained in:
kiyan42 2020-09-06 15:32:24 +02:00
parent 981f3f17a0
commit 7e0c4e5329

View File

@ -99,11 +99,7 @@ function TSHighlighter:get_hl_from_capture(capture)
else
-- Default to false to avoid recomputing
local hl = TSHighlighter.hl_map[name]
if hl then
return a.nvim_get_hl_id_by_name(hl)
else
return 0
end
return hl and a.nvim_get_hl_id_by_name(hl) or 0
end
end