makes plugin compatible with old vim installations that do not have quitpre

This commit is contained in:
yogesh nachnani 2017-04-30 17:24:19 +05:30
parent dcfaf16a96
commit 108e2e5024

View file

@ -455,7 +455,9 @@ let s:VERSION = '5.0.1'
autocmd BufEnter,VimEnter * call s:InitAndHandleActivity(s:false)
autocmd CursorMoved,CursorMovedI * call s:HandleActivity(s:false)
autocmd BufWritePost * call s:HandleActivity(s:true)
autocmd QuitPre * call s:SendHeartbeats()
if exists('##QuitPre')
autocmd QuitPre * call s:SendHeartbeats()
endif
augroup END
" }}}