fix builtin.autocommands throwing error (#1758)
This commit is contained in:
@@ -933,7 +933,7 @@ previewers.autocommands = defaulter(function(_)
|
||||
-- set the cursor position after self.state.bufnr is connected to the
|
||||
-- preview window (which is scheduled in new_buffer_previewer)
|
||||
vim.schedule(function()
|
||||
vim.api.nvim_win_set_cursor(status.preview_win, { selected_row, 0 })
|
||||
pcall(vim.api.nvim_win_set_cursor, status.preview_win, { selected_row, 0 })
|
||||
end)
|
||||
|
||||
self.state.last_set_bufnr = self.state.bufnr
|
||||
|
||||
Reference in New Issue
Block a user