aboutsummaryrefslogtreecommitdiff
path: root/runtime
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2016-08-21 16:15:50 -0400
committerJustin M. Keyes <justinkz@gmail.com>2016-08-21 22:03:28 -0400
commit297677ecf42501d2bef45dd4f083002a0963b205 (patch)
tree57702cc022f34b12b873c288456bddb4db0b5134 /runtime
parent45cc14d9a5c1d5eadf817c920de5f913bbc4d772 (diff)
downloadrneovim-297677ecf42501d2bef45dd4f083002a0963b205.tar.gz
rneovim-297677ecf42501d2bef45dd4f083002a0963b205.tar.bz2
rneovim-297677ecf42501d2bef45dd4f083002a0963b205.zip
remote/host.vim: Avoid "No matching autocommands".
:silent does not silence this message, even :redir does not consume it. But execute() _does_ consume it, which interferes with the current implementation of health.vim. It's prudent to avoid it in any case, even if the implementation of health.vim changes in the future.
Diffstat (limited to 'runtime')
-rw-r--r--runtime/autoload/remote/host.vim4
1 files changed, 3 insertions, 1 deletions
diff --git a/runtime/autoload/remote/host.vim b/runtime/autoload/remote/host.vim
index 065644121a..110f80297a 100644
--- a/runtime/autoload/remote/host.vim
+++ b/runtime/autoload/remote/host.vim
@@ -178,7 +178,9 @@ endfunction
function! remote#host#LoadRemotePluginsEvent(event, pattern) abort
autocmd! nvim-rplugin
call remote#host#LoadRemotePlugins()
- execute 'silent doautocmd <nomodeline>' a:event a:pattern
+ if exists('#'.a:event.'#'.a:pattern) " Avoid 'No matching autocommands'.
+ execute 'silent doautocmd <nomodeline>' a:event a:pattern
+ endif
endfunction