Skip to content

Commit

Permalink
fix: checker should not error on non-existing dirs
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed Dec 20, 2022
1 parent 50ba619 commit ddf36d7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lua/lazy/manage/checker.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ function M.fast_check()
if plugin._.installed then
plugin._.has_updates = nil
local info = Git.info(plugin.dir)
local target = Git.get_target(plugin)
if info and target and info.commit ~= target.commit then
local ok, target = pcall(Git.get_target, plugin)
if ok and info and target and info.commit ~= target.commit then
plugin._.has_updates = true
end
end
Expand Down

0 comments on commit ddf36d7

Please sign in to comment.