diff options
author | Yasuhiro Matsumoto <mattn.jp@gmail.com> | 2020-01-30 09:17:14 +0900 |
---|---|---|
committer | Yasuhiro Matsumoto <mattn.jp@gmail.com> | 2020-01-30 09:17:14 +0900 |
commit | 6694c211f51b67176029c558686e2393329cc892 (patch) | |
tree | d7be63f2f5405bdda33c19c815ce870c6e8595e2 /autoload/lsp_settings.vim | |
parent | 6690922a98b1c623c5703d5cacde7adf795124cd (diff) | |
download | vim-lsp-settings-6694c211f51b67176029c558686e2393329cc892.tar.gz vim-lsp-settings-6694c211f51b67176029c558686e2393329cc892.tar.bz2 vim-lsp-settings-6694c211f51b67176029c558686e2393329cc892.zip |
Check lsp_setup exists
Diffstat (limited to 'autoload/lsp_settings.vim')
-rw-r--r-- | autoload/lsp_settings.vim | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/autoload/lsp_settings.vim b/autoload/lsp_settings.vim index 1596762..bbcf208 100644 --- a/autoload/lsp_settings.vim +++ b/autoload/lsp_settings.vim @@ -385,7 +385,9 @@ function! s:vim_lsp_load_or_suggest(ft) abort if l:disabled == 0 && l:found ==# 0 call s:vim_lsp_settings_suggest(a:ft) else - doautocmd User lsp_setup + if exists('#lsp_settings') !=# 0 + doautocmd User lsp_setup + endif if exists(':LspInstallServer') !=# 2 command! -nargs=? -buffer -complete=customlist,lsp_settings#complete_install LspInstallServer call s:vim_lsp_install_server(&l:filetype, <q-args>) endif @@ -409,9 +411,7 @@ function! lsp_settings#init() abort augroup vim_lsp_suggest autocmd! autocmd BufNewFile,BufRead * call s:vim_lsp_suggest_plugin() - autocmd VimEnter * call s:vim_lsp_load_or_suggest('_') augroup END command! -nargs=? -complete=customlist,lsp_settings#complete_uninstall LspUninstallServer call s:vim_lsp_uninstall_server(<q-args>) call s:vim_lsp_load_or_suggest('_') - endfunction |