Skip to content

Commit fedd5f1

Browse files
author
marty
committed
minor refactor
1 parent dc108f5 commit fedd5f1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Diff for: plugin/NERD_tree.vim

+2-2
Original file line numberDiff line numberDiff line change
@@ -2658,7 +2658,7 @@ function! s:centerView()
26582658
endif
26592659
endfunction
26602660
"FUNCTION: s:closeTree() {{{2
2661-
"Closes the NERD tree window
2661+
"Closes the primary NERD tree window for this tab
26622662
function! s:closeTree()
26632663
if !s:isTreeOpen()
26642664
throw "NERDTree.NoTreeFoundError: no NERDTree is open"
@@ -3580,7 +3580,7 @@ function! s:closeTreeWindow()
35803580
exec "buffer " . b:NERDTreePreviousBuf
35813581
else
35823582
if winnr("$") > 1
3583-
wincmd c
3583+
call s:closeTree()
35843584
else
35853585
call s:echo("Cannot close last window")
35863586
endif

0 commit comments

Comments
 (0)