fix: silence doautocmd errors
This produced an error when the ssh adapter terminal was open, and then a connection error occurred. It would produce a `Can't re-enter normal mode from terminal mode` error.
This commit is contained in:
parent
9f7c4d74e1
commit
9dbf18a524
1 changed files with 2 additions and 2 deletions
|
|
@ -541,9 +541,9 @@ M.setup = function(opts)
|
|||
if new_url ~= params.file then
|
||||
util.rename_buffer(bufnr, new_url)
|
||||
end
|
||||
vim.cmd.doautocmd({ args = { "BufReadPre", params.file }, mods = { silent = true } })
|
||||
vim.cmd.doautocmd({ args = { "BufReadPre", params.file }, mods = { emsg_silent = true } })
|
||||
view.initialize(bufnr)
|
||||
vim.cmd.doautocmd({ args = { "BufReadPost", params.file }, mods = { silent = true } })
|
||||
vim.cmd.doautocmd({ args = { "BufReadPost", params.file }, mods = { emsg_silent = true } })
|
||||
end
|
||||
|
||||
if adapter.normalize_url then
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue