From bdf81a086dd271571104a11f555b79e5cdff5dc5 Mon Sep 17 00:00:00 2001 From: Ali Rezvani <3788964+rzvxa@users.noreply.github.com> Date: Sun, 11 Feb 2024 16:27:41 +0330 Subject: [PATCH] fix: GetWinNum regex pattern. (#1409) --- lib/nerdtree/nerdtree.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/nerdtree/nerdtree.vim b/lib/nerdtree/nerdtree.vim index 61a11a9..1af5346 100644 --- a/lib/nerdtree/nerdtree.vim +++ b/lib/nerdtree/nerdtree.vim @@ -144,7 +144,7 @@ function! s:NERDTree.GetWinNum() " If WindowTree, there is no t:NERDTreeBufName variable. Search all windows. for w in range(1,winnr('$')) - if bufname(winbufnr(w)) =~# '^' . g:NERDTreeCreator.BufNamePrefix() . '\d\+$' + if bufname(winbufnr(w)) =~# '^' . g:NERDTreeCreator.BufNamePrefix() . 'win_\d\+$' return w endif endfor