mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-21 12:50:09 -04:00
remove second check
This commit is contained in:
parent
fe8e16ba98
commit
9641a912ea
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