From bb53d6c380df702b4e85130aa584b64101113502 Mon Sep 17 00:00:00 2001 From: Yasuhiro Matsumoto Date: Fri, 19 Jul 2019 17:58:30 +0900 Subject: [PATCH] Check function exists --- autoload/go/util.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/autoload/go/util.vim b/autoload/go/util.vim index 2ed41af3e0..ec4ea0ebb1 100644 --- a/autoload/go/util.vim +++ b/autoload/go/util.vim @@ -93,7 +93,7 @@ function! go#util#env(key) abort return s:env_cache[l:key] endif - if executable('go') + if executable('go') && exists('*go#util#'.l:key) let l:var = call('go#util#'.l:key, []) if go#util#ShellError() != 0 call go#util#EchoError(printf("'go env %s' failed", toupper(l:key)))