buflist: do not consider empty buffers to be excluded
currently, empty buffer names were still considered to match against the exclude_path setting. That does not make sense, so skip the check for empty bufnames.
This commit is contained in:
parent
0a1f4cc910
commit
916d023c35
@ -14,7 +14,11 @@ endfunction
|
||||
|
||||
" paths in excludes list
|
||||
function! s:ExcludePaths(nr, exclude_paths)
|
||||
let bpath = fnamemodify(bufname(a:nr), ":p")
|
||||
let bname = bufname(a:nr)
|
||||
if empty(bname)
|
||||
return 0
|
||||
endif
|
||||
let bpath = fnamemodify(bname, ":p")
|
||||
for f in a:exclude_paths
|
||||
if bpath =~# f | return 1 | endif
|
||||
endfor
|
||||
|
@ -358,7 +358,7 @@ The "!" prevents terminal buffers to appear in the tabline.
|
||||
|
||||
*airline#extensions#tabline#exclude_buffers*
|
||||
Buffer numbers to be excluded from showing in the tabline (similar to
|
||||
|airline#ignore_bufadd_pat|.
|
||||
|airline#ignore_bufadd_pat|).
|
||||
|
||||
==============================================================================
|
||||
EXTENSIONS *airline-extensions*
|
||||
|
Loading…
Reference in New Issue
Block a user