fix: guard vim.lsp.diagnostics.refresh() against nil
Neovim 0.12+ restructured LSP internals; vim.lsp.diagnostics no longer exists as a submodule. Guard the call so :SCLRescanWorkspaceTypes doesn't crash on startup.
This commit is contained in:
@@ -338,7 +338,9 @@ function M.rescan_workspace_types()
|
|||||||
end, 0)
|
end, 0)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if vim.lsp.diagnostics then
|
||||||
vim.lsp.diagnostics.refresh()
|
vim.lsp.diagnostics.refresh()
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function M.create_commands()
|
function M.create_commands()
|
||||||
|
|||||||
Reference in New Issue
Block a user