From 07a2b274ee5559e9a22e7f3814a3fc9361d31a13 Mon Sep 17 00:00:00 2001 From: Fast Code <95887682+ProFastCode@users.noreply.github.com> Date: Thu, 8 May 2025 02:09:44 +0300 Subject: [PATCH] Update init.lua --- lua/lazyvim/plugins/lsp/init.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lua/lazyvim/plugins/lsp/init.lua b/lua/lazyvim/plugins/lsp/init.lua index 6ba4597f..cbe37cf2 100644 --- a/lua/lazyvim/plugins/lsp/init.lua +++ b/lua/lazyvim/plugins/lsp/init.lua @@ -211,8 +211,9 @@ return { -- get all the servers that are available through mason-lspconfig local have_mason, mlsp = pcall(require, "mason-lspconfig") local all_mslp_servers = {} + if have_mason then - all_mslp_servers = vim.tbl_keys(require("mason-lspconfig.mappings.server").lspconfig_to_package) + all_mslp_servers = mlsp.get_available_servers() end local ensure_installed = {} ---@type string[]