Skip to content

Commit 7f5a8c3

Browse files
committed
Fix for getting line of node
Set curPathComponent to 0 correctly identify with indent level of node.
1 parent 1dd345c commit 7f5a8c3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugin/NERD_tree.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -991,7 +991,7 @@ function! s:TreeFileNode.getLineNum()
991991
"the path components we have matched so far
992992
let pathcomponents = [substitute(b:NERDTreeRoot.path.str({'format': 'UI'}), '/ *$', '', '')]
993993
"the index of the component we are searching for
994-
let curPathComponent = 1
994+
let curPathComponent = 0
995995

996996
let fullpath = self.path.str({'format': 'UI'})
997997

0 commit comments

Comments
 (0)