wordcount: prevent use of unused variable

This commit is contained in:
Christian Brabandt
2018-12-10 09:11:10 +01:00
parent 3d9071e6b6
commit e3cfd3643b

View File

@@ -73,11 +73,11 @@ function airline#extensions#wordcount#get()
if s:visual_active
return s:format_wordcount(s:get_wordcount(1))
else
if b:airline_changedtick != b:changedtick
if get(b:, 'airline_changedtick', 0) != b:changedtick
call s:update_wordcount(0)
let b:airline_changedtick = b:changedtick
endif
return b:airline_wordcount
return get(b:, 'airline_wordcount', '')
endif
endfunction