mirror of https://github.com/folke/lazy.nvim.git
fix(plugin): prevent recursive loop with cond=false. Fixes #1061
This commit is contained in:
parent
6a2c47e642
commit
09e5010741
|
@ -252,10 +252,12 @@ function Spec:fix_cond()
|
||||||
local stack = { plugin }
|
local stack = { plugin }
|
||||||
while #stack > 0 do
|
while #stack > 0 do
|
||||||
local p = table.remove(stack)
|
local p = table.remove(stack)
|
||||||
for _, dep in ipairs(p.dependencies or {}) do
|
if not self.ignore_installed[p.name] then
|
||||||
table.insert(stack, self.plugins[dep])
|
for _, dep in ipairs(p.dependencies or {}) do
|
||||||
|
table.insert(stack, self.plugins[dep])
|
||||||
|
end
|
||||||
|
self.ignore_installed[p.name] = true
|
||||||
end
|
end
|
||||||
self.ignore_installed[p.name] = true
|
|
||||||
end
|
end
|
||||||
plugin.enabled = false
|
plugin.enabled = false
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue