mirror of
https://github.com/gryf/tagbar.git
synced 2026-10-06 21:50:36 +02:00
Fix statusline bug when opening Tagbar without having a valid file loaded
This commit is contained in:
1 parent
3e4bd07b48
commit
4d5b30b1ce
1 file changed
+4
-2
+4
-2
@@ -2435,8 +2435,10 @@ function! TagbarGenerateStatusline()
|
||||
let text = '[Order]'
|
||||
endif
|
||||
|
||||
let filename = fnamemodify(s:known_files.getCurrent().fpath, ':t')
|
||||
let text .= ' ' . filename
|
||||
if !empty(s:known_files.getCurrent())
|
||||
let filename = fnamemodify(s:known_files.getCurrent().fpath, ':t')
|
||||
let text .= ' ' . filename
|
||||
endif
|
||||
|
||||
return text
|
||||
endfunction
|
||||
|
||||
Reference in new issue
Block a user