Fix the drive check in "TreeDirNode._glob()"

This check did not use the proper abstract method to check for a
path separator. It now does.

This fixes a problem with the 'u' macro that I noticed while working
on the fix for using the NERDTree with 'shellslash'.
This commit is contained in:
Jason Franklin 2017-08-11 10:13:12 -04:00
parent a32a55e8d9
commit d7cf9a2a98

View File

@ -243,7 +243,7 @@ function! s:TreeDirNode._glob(pattern, all)
let l:pathSpec = fnamemodify(self.path.str({'format': 'Glob'}), ':.')
" On Windows, the drive letter may be removed by "fnamemodify()".
if nerdtree#runningWindows() && l:pathSpec[0] == '\'
if nerdtree#runningWindows() && l:pathSpec[0] == g:NERDTreePath.Slash()
let l:pathSpec = self.path.drive . l:pathSpec
endif
endif