Skip to content

Commit

Permalink
update: normalize consecutive slashes
Browse files Browse the repository at this point in the history
  • Loading branch information
amedama41 committed Aug 6, 2023
1 parent 1058f4f commit e306ec7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/vfiler/libs/core.lua
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ function M.path.normalize(path)
if path == '/' then
return '/'
end
return M.path.escape(vim.fn.fnamemodify(path, ':p'))
return M.path.escape(vim.fn.fnamemodify(path, ':p')):gsub('/+', '/')
end

function M.path.parent(path)
Expand Down

0 comments on commit e306ec7

Please sign in to comment.