[vim] Empty out $FZF_DEFAULT_COMMAND before unletting it

For Vim 8.0.1831 and below
* https://github.com/vim/vim/issues/1116

Fix https://github.com/junegunn/fzf.vim/issues/1301
This commit is contained in:
Junegunn Choi 2021-10-10 20:16:59 +09:00
parent 179993f0cd
commit 2736a2f69e
No known key found for this signature in database
GPG Key ID: 254BC280FEF9C627
1 changed files with 2 additions and 1 deletions

View File

@ -519,7 +519,8 @@ finally
if len(prev_default_command)
let $FZF_DEFAULT_COMMAND = prev_default_command
else
execute 'unlet $FZF_DEFAULT_COMMAND'
let $FZF_DEFAULT_COMMAND = ''
silent! execute 'unlet $FZF_DEFAULT_COMMAND'
endif
endif
let [&shell, &shellslash, &shellcmdflag, &shellxquote] = [shell, shellslash, shellcmdflag, shellxquote]