Skip to content

Commit

Permalink
style(cache): removed hack for relative paths
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed Feb 27, 2023
1 parent 5694483 commit b814d87
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions lua/lazy/core/cache.lua
Original file line number Diff line number Diff line change
Expand Up @@ -231,13 +231,6 @@ function Cache.find(modname, opts)
local basename = modname:gsub("%.", "/")
local idx = modname:find(".", 1, true)

-- HACK: some plugins try to load invalid relative paths (see #543)
if idx == 1 then
modname = modname:gsub("^%.+", "")
basename = modname:gsub("%.", "/")
idx = modname:find(".", 1, true)
end

local topmod = idx and modname:sub(1, idx - 1) or modname

-- OPTIM: search for a directory first when topmod == modname
Expand Down

0 comments on commit b814d87

Please sign in to comment.