From bedab7e87b038da11f93484c1bc1e036fea520b9 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Sat, 5 Sep 2020 15:02:46 -0700 Subject: provider: align all foo#Detect() functions #12839 Problem: ruby#Detect() and node#Detect() don't return a [prog, err] pair which means callers must special-case them. Solution: align their return signatures with the perl/pythonx providers. --- runtime/autoload/provider/ruby.vim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'runtime/autoload/provider/ruby.vim') diff --git a/runtime/autoload/provider/ruby.vim b/runtime/autoload/provider/ruby.vim index f843050df9..1f49c623ac 100644 --- a/runtime/autoload/provider/ruby.vim +++ b/runtime/autoload/provider/ruby.vim @@ -5,7 +5,8 @@ endif let g:loaded_ruby_provider = 1 function! provider#ruby#Detect() abort - return s:prog + let e = empty(s:prog) ? 'missing ruby or ruby-host' : '' + return [s:prog, e] endfunction function! provider#ruby#Prog() abort -- cgit