diff options
author | opalmay <[email protected]> | 2022-11-14 11:16:49 +0200 |
---|---|---|
committer | GitHub <[email protected]> | 2022-11-14 10:16:49 +0100 |
commit | 8474a06b43d539becd92024fdd4306ee89a6fd08 (patch) | |
tree | cd7262ef684c962ca1631cd74b3f3a04614e28a8 /lua/lvim/lsp | |
parent | 5fb3f07c7bf94b5f0dd3833023a878876af95365 (diff) |
fix(lsp): some servers have dynamic commands (#3471)
Diffstat (limited to 'lua/lvim/lsp')
-rw-r--r-- | lua/lvim/lsp/manager.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lua/lvim/lsp/manager.lua b/lua/lvim/lsp/manager.lua index 02f0f600..b99f7531 100644 --- a/lua/lvim/lsp/manager.lua +++ b/lua/lvim/lsp/manager.lua @@ -77,7 +77,8 @@ local function launch_server(server_name, config) local default_config = require("lspconfig.server_configurations." .. server_name).default_config return default_config.cmd end)() - if vim.fn.executable(command[1]) ~= 1 then + -- some servers have dynamic commands defined with on_new_config + if type(command) == "table" and type(command[1]) == "string" and vim.fn.executable(command[1]) ~= 1 then Log:debug(string.format("[%q] is either not installed, missing from PATH, or not executable.", server_name)) return end |