Browse Source

Fix bug with plugin configuration being passed to vim-plug

master
Adam Pippin 2 years ago
parent
commit
ee3664f0e3
  1. 2
      lua/module/plugins.lua
  2. 2
      lua/plugin/vim_plug.lua

2
lua/module/plugins.lua

@ -85,7 +85,7 @@ function M:commit()
-- will never be enabled so we can explicitly disable and remove it.
elseif (
(not plugin_enabled) or
(not plugin_installed) or
(not plugin_installed and not self.auto_install) or
(not plugin_required_providers) or
(not plugin_required_binaries)
) then

2
lua/plugin/vim_plug.lua

@ -18,7 +18,7 @@ function M:add(name, config)
-- TODO: we're getting passed through the "opts" from the plugin config
-- this should pull out only the values we need and put them in the format
-- vim-plug expects
if (type(config) == "nil" or #config == 0) then
if (type(config) == "nil" or next(config) == nil) then
vim.fn['plug#'](name)
else
vim.fn['plug#'](name, config)

Loading…
Cancel
Save