mirror of
https://github.com/preservim/nerdtree.git
synced 2025-11-08 11:23:48 -05:00
Fix call to globpath() for Vim 7.2 and below.
globpath() takes an extra optional parameter in Vim 7.3, but this breaks NERD tree on earlier versions.
This commit is contained in:
@@ -1618,7 +1618,13 @@ function! s:TreeDirNode._initChildren(silent)
|
|||||||
"get an array of all the files in the nodes dir
|
"get an array of all the files in the nodes dir
|
||||||
let dir = self.path
|
let dir = self.path
|
||||||
let globDir = dir.str({'format': 'Glob'})
|
let globDir = dir.str({'format': 'Glob'})
|
||||||
let filesStr = globpath(globDir, '*',1) . "\n" . globpath(globDir, '.*',1)
|
|
||||||
|
if version >= 703
|
||||||
|
let filesStr = globpath(globDir, '*', 1) . "\n" . globpath(globDir, '.*', 1)
|
||||||
|
else
|
||||||
|
let filesStr = globpath(globDir, '*') . "\n" . globpath(globDir, '.*')
|
||||||
|
endif
|
||||||
|
|
||||||
let files = split(filesStr, "\n")
|
let files = split(filesStr, "\n")
|
||||||
|
|
||||||
if !a:silent && len(files) > g:NERDTreeNotificationThreshold
|
if !a:silent && len(files) > g:NERDTreeNotificationThreshold
|
||||||
|
|||||||
Reference in New Issue
Block a user