File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -25,12 +25,12 @@ local function store_client_id(id)
2525 M .id = id
2626end
2727
28+ local function reuse_client (client , conf )
29+ return client .config .root_dir == conf .root_dir and client .name == conf .name
30+ end
31+
2832local lsp_start = vim .lsp .start
2933if not lsp_start then
30- local function reuse_client (client , conf )
31- return client .config .root_dir == conf .root_dir and client .name == conf .name
32- end
33-
3434 -- shim for neovim < 0.8.2
3535 lsp_start = function (lsp_config )
3636 local bufnr = vim .api .nvim_get_current_buf ()
@@ -97,7 +97,7 @@ function M.buf_attach(force)
9797 return
9898 end
9999
100- local client_id = lsp_start (M .config )
100+ local client_id = lsp_start (M .config , { reuse_client = reuse_client , bufnr = M . id } )
101101 store_client_id (client_id )
102102end
103103
You can’t perform that action at this time.
0 commit comments