Remove old lspconfig hack

This commit is contained in:
ViViDboarder 2024-06-17 09:55:50 -07:00
parent 2710af9160
commit 80ad56a2b1

View File

@ -6,12 +6,7 @@ local function disable_formatter_filetypes_for_existing_servers(sources, preserv
local server_filetypes = {}
utils.try_require("lspconfig", function(lsp_config)
local available_servers
if lsp_config["util"] and lsp_config.util["available_servers"] then
available_servers = lsp_config.util.available_servers()
else
-- HACK: For lspconfig versions lower than 0.1.4, which is required for nvim <0.7.0
available_servers = lsp_config.available_servers()
end
vim.tbl_map(function(server)
if lsp_config[server].filetypes ~= nil then
vim.list_extend(server_filetypes, lsp_config[server].filetypes)