mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-01 19:17:02 -04:00
remove second check
This commit is contained in:
parent
cf9df71341
commit
ac13baadb6
1 changed files with 1 additions and 2 deletions
|
|
@ -20,8 +20,7 @@ end
|
|||
function M.get_package_path()
|
||||
for _, path in pairs(api.nvim_list_runtime_paths()) do
|
||||
local last_segment = vim.fn.fnamemodify(path, ":p:h:t")
|
||||
local penultimate_segment = vim.fn.fnamemodify(path, ":p:h:t:t")
|
||||
if last_segment == "nvim-treesitter" or (last_segment == "" and penultimate_segment == "nvim-treesitter") then
|
||||
if last_segment == "nvim-treesitter" then
|
||||
return path
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue