We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 71122d7 commit 84126d3Copy full SHA for 84126d3
lua/nvim-tree/lib.lua
@@ -85,13 +85,14 @@ local function get_line_from_node(node, find_parent)
85
local line = 2
86
local function iter(entries, recursive)
87
for _, entry in ipairs(entries) do
88
- if node_path:match('^'..entry.match_path..'$') ~= nil then
+ local n = M.get_last_group_node(entry)
89
+ if node_path:match('^'..n.match_path..'$') ~= nil then
90
return line, entry
91
end
92
93
line = line + 1
- if entry.open == true and recursive then
94
- local _, child = iter(entry.entries, recursive)
+ if n.open == true and recursive then
95
+ local _, child = iter(n.entries, recursive)
96
if child ~= nil then return line, child end
97
98
0 commit comments