We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1f05774 commit 2bc56adCopy full SHA for 2bc56ad
lua/oil/init.lua
@@ -640,6 +640,7 @@ M.select = function(opts, callback)
640
end
641
642
local prev_win = vim.api.nvim_get_current_win()
643
+ local oil_bufnr = vim.api.nvim_get_current_buf()
644
645
-- Async iter over entries so we can normalize the url before opening
646
local i = 1
@@ -665,7 +666,7 @@ M.select = function(opts, callback)
665
666
667
-- Normalize the url before opening to prevent needing to rename them inside the BufReadCmd
668
-- Renaming buffers during opening can lead to missed autocmds
- util.get_edit_path(0, entry, function(normalized_url)
669
+ util.get_edit_path(oil_bufnr, entry, function(normalized_url)
670
local mods = {
671
vertical = opts.vertical,
672
horizontal = opts.horizontal,
0 commit comments