Skip to content

Commit a7f5346

Browse files
fix: always use pcall to check for treesitter parser
1 parent eae0d8f commit a7f5346

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

lua/telescope/utils.lua

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -662,11 +662,7 @@ end)
662662
--- Checks if treesitter parser for language is installed
663663
---@param lang string
664664
utils.has_ts_parser = function(lang)
665-
if vim.fn.has "nvim-0.11" == 1 then
666-
return vim.treesitter.language.add(lang)
667-
else
668-
return pcall(vim.treesitter.language.add, lang)
669-
end
665+
return pcall(vim.treesitter.language.add, lang)
670666
end
671667

672668
--- Telescope Wrapper around vim.notify

0 commit comments

Comments
 (0)