From 0852047c90083692d418908b18dd89bed708550b Mon Sep 17 00:00:00 2001 From: gmarik Date: Mon, 28 Mar 2011 13:05:26 -0500 Subject: [PATCH] use empty() where possible --- autoload/vundle/installer.vim | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/autoload/vundle/installer.vim b/autoload/vundle/installer.vim index 718d07a..c553793 100644 --- a/autoload/vundle/installer.vim +++ b/autoload/vundle/installer.vim @@ -8,10 +8,10 @@ func! vundle#installer#install(bang, ...) redraw! call vundle#config#require(bundles) - call s:log("Installed bundles:\n".join((len(installed) == 0 ? ['no new bundless installed'] : map(installed, 'v:val.name')),"\n")) + call s:log("Installed bundles:\n".join((empty(installed) ? ['no new bundless installed'] : map(installed, 'v:val.name')),"\n")) let help_dirs = vundle#installer#helptags(bundles) - if len(help_dirs) > 0 + if !empty(help_dirs) call s:log('Helptags: done. '.len(help_dirs).' bundles processed') endif endf @@ -45,7 +45,7 @@ endf func! s:has_doc(rtp) return isdirectory(a:rtp.'/doc') \ && (!filereadable(a:rtp.'/doc/tags') || filewritable(a:rtp.'/doc/tags')) - \ && (len(glob(a:rtp.'/doc/*.txt')) > 0 || len(glob(a:rtp.'/doc/*.??x')) > 0) + \ && !(empty(glob(a:rtp.'/doc/*.txt')) && empty(glob(a:rtp.'/doc/*.??x'))) endf func! s:helptags(rtp)