diff --git a/plugin/tagbar.vim b/plugin/tagbar.vim index 68bd702..a7e5e7e 100644 --- a/plugin/tagbar.vim +++ b/plugin/tagbar.vim @@ -2480,14 +2480,14 @@ function! s:AutoUpdate(fname) return endif - " Don't do anything if the file isn't supported - if !s:IsValidFile(a:fname, &filetype) - return - endif - " Only consider the main filetype in cases like 'python.django' let ftype = split(&filetype, '\.')[0] + " Don't do anything if the file isn't supported + if !s:IsValidFile(a:fname, ftype) + return + endif + " Process the file if it's unknown or the information is outdated " Also test for entries that exist but are empty, which will be the case " if there was an error during the ctags execution