fix(manage): only clear plugins for the op instead of all

This commit is contained in:
Folke Lemaitre 2022-12-24 11:16:24 +01:00
parent 74d8b8e4e1
commit fc182f7c5d
No known key found for this signature in database
GPG Key ID: 41F8B1FBACAE2040
1 changed files with 4 additions and 3 deletions

View File

@ -28,7 +28,7 @@ function M.run(ropts, opts)
ropts.concurrency = ropts.concurrency or opts.concurrency or Config.options.concurrency
if opts.clear then
M.clear()
M.clear(opts.plugins)
end
if opts.show ~= false then
@ -162,8 +162,9 @@ function M.clean(opts)
end)
end
function M.clear()
for _, plugin in pairs(Config.plugins) do
---@param plugins? LazyPlugin[]
function M.clear(plugins)
for _, plugin in pairs(plugins or Config.plugins) do
plugin._.has_updates = nil
plugin._.updated = nil
plugin._.cloned = nil