summaryrefslogtreecommitdiff
path: root/autoload
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2018-07-03 21:14:00 +0100
committerw0rp <devw0rp@gmail.com>2018-07-03 21:14:00 +0100
commit602e7fa00f50de2af3a35e1cc0a536be07947d5a (patch)
treeb2f793782f3bd92d91fedb2fc2d41d7ec821be7d /autoload
parente10e0934ab235976f5006152e6bb44663b95ab07 (diff)
downloadale-602e7fa00f50de2af3a35e1cc0a536be07947d5a.zip
#1524 Avoid loading cursor code until engine code has been loaded
Diffstat (limited to 'autoload')
-rw-r--r--autoload/ale/events.vim4
1 files changed, 2 insertions, 2 deletions
diff --git a/autoload/ale/events.vim b/autoload/ale/events.vim
index 44ef4b7a..4bc5cde1 100644
--- a/autoload/ale/events.vim
+++ b/autoload/ale/events.vim
@@ -122,11 +122,11 @@ function! ale#events#Init() abort
endif
if g:ale_echo_cursor
- autocmd CursorMoved,CursorHold * call ale#cursor#EchoCursorWarningWithDelay()
+ autocmd CursorMoved,CursorHold * if exists('*ale#engine#Cleanup') | call ale#cursor#EchoCursorWarningWithDelay() | endif
" Look for a warning to echo as soon as we leave Insert mode.
" The script's position variable used when moving the cursor will
" not be changed here.
- autocmd InsertLeave * call ale#cursor#EchoCursorWarning()
+ autocmd InsertLeave * if exists('*ale#engine#Cleanup') | call ale#cursor#EchoCursorWarning() | endif
endif
endif
augroup END