mirror of
https://github.com/LazyVim/LazyVim.git
synced 2025-06-21 16:39:06 +02:00
fix(extras): don't load pkgs when parsing specs for LazyExtras
This commit is contained in:
parent
683bf52c02
commit
3764735fb2
1 changed files with 2 additions and 2 deletions
|
@ -84,13 +84,13 @@ end
|
||||||
---@param source LazyExtraSource
|
---@param source LazyExtraSource
|
||||||
function M.get_extra(source, modname)
|
function M.get_extra(source, modname)
|
||||||
local enabled = vim.tbl_contains(M.state, modname)
|
local enabled = vim.tbl_contains(M.state, modname)
|
||||||
local spec = Plugin.Spec.new(nil, { optional = true })
|
local spec = Plugin.Spec.new(nil, { optional = true, pkg = false })
|
||||||
spec:parse({ import = modname })
|
spec:parse({ import = modname })
|
||||||
local imports = vim.tbl_filter(function(x)
|
local imports = vim.tbl_filter(function(x)
|
||||||
return x ~= modname
|
return x ~= modname
|
||||||
end, spec.modules)
|
end, spec.modules)
|
||||||
if #imports > 0 then
|
if #imports > 0 then
|
||||||
spec = Plugin.Spec.new(nil, { optional = true })
|
spec = Plugin.Spec.new(nil, { optional = true, pkg = false })
|
||||||
spec.modules = vim.deepcopy(imports)
|
spec.modules = vim.deepcopy(imports)
|
||||||
spec:parse({ import = modname })
|
spec:parse({ import = modname })
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue