From 0678df38e9df7f2c768fa92789bc1772e51f875c Mon Sep 17 00:00:00 2001 From: Rane Brown Date: Sat, 20 Jul 2019 22:13:48 -0600 Subject: [PATCH] Support getbufvar for vim < v7.3.831 --- autoload/vimwiki/vars.vim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/autoload/vimwiki/vars.vim b/autoload/vimwiki/vars.vim index cbe47ea..b855a95 100644 --- a/autoload/vimwiki/vars.vim +++ b/autoload/vimwiki/vars.vim @@ -888,7 +888,8 @@ endfunction function! vimwiki#vars#get_bufferlocal(key, ...) let buffer = a:0 ? a:1 : '%' - let value = getbufvar(buffer, 'vimwiki_'.a:key, '/\/\') + " 'get(getbufvar(...' handles vim < v7.3.831 that didn't allow a default value for getbufvar + let value = get(getbufvar(buffer, ''), 'vimwiki_'.a:key, '/\/\') if type(value) != 1 || value !=# '/\/\' return value elseif a:key ==# 'wiki_nr'