diff --git a/lua/lazy/core/cache.lua b/lua/lazy/core/cache.lua index f244f84..6fa9711 100644 --- a/lua/lazy/core/cache.lua +++ b/lua/lazy/core/cache.lua @@ -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, modpath + return root, (modpath ~= root and modpath or nil) end end