Bug
fzf#vim#colors() throws E728: Using a Dictionary as a Number on line 614 of autoload/fzf/vim.vim when called with a spec dict as the first argument.
Cause
if !a:1 " We can't set up IPC in fullscreen mode in Vim
This assumes a:1 is always a number (<bang>0 from the :Colors command), but the function's public API accepts ([spec dict], [fullscreen bool]) — so a:1 can be a dictionary.
Steps to reproduce
Suggested fix
if a:0 && type(a:1) != s:TYPE.dict && !a:1
This matches how s:fzf() (line 322) already handles the same varargs pattern.
Version
Latest master (34a564c81f)
Introduced in 04bfa81157 ([Colors] Change color scheme on the fly (experimental)).
Bug
fzf#vim#colors()throwsE728: Using a Dictionary as a Numberon line 614 ofautoload/fzf/vim.vimwhen called with a spec dict as the first argument.Cause
This assumes
a:1is always a number (<bang>0from the:Colorscommand), but the function's public API accepts([spec dict], [fullscreen bool])— soa:1can be a dictionary.Steps to reproduce
Suggested fix
This matches how
s:fzf()(line 322) already handles the same varargs pattern.Version
Latest master (
34a564c81f)Introduced in
04bfa81157([Colors] Change color scheme on the fly (experimental)).