mirror of
https://github.com/neovim/neovim.git
synced 2025-09-06 11:28:22 +00:00
refactor: use vim._with
where possible
This mostly means replacing `nvim_buf_call` and `nvim_win_call` with `vim._with`.
This commit is contained in:
@@ -257,7 +257,7 @@ end
|
||||
function Session:restore_keymaps()
|
||||
local function restore(keymap, lhs, mode)
|
||||
if keymap then
|
||||
vim.api.nvim_buf_call(self.bufnr, function()
|
||||
vim._with({ buf = self.bufnr }, function()
|
||||
vim.fn.mapset(keymap)
|
||||
end)
|
||||
else
|
||||
|
Reference in New Issue
Block a user