Skip to content

Commit

Permalink
fix(cache): properly return two values for finddir
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed Jan 2, 2023
1 parent 8b6a98a commit 1ec8f08
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/lazy/core/cache.lua
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ function M.find_dir(modname)
local modpath = M.find(modname, { patterns = { "" } })
if modpath then
local root = modpath:gsub("/init%.lua$", ""):gsub("%.lua$", "")
return root, root ~= modpath and modpath or nil
return root, (root ~= modpath and modpath or nil)
end
end

Expand Down

0 comments on commit 1ec8f08

Please sign in to comment.