-
Notifications
You must be signed in to change notification settings - Fork 325
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Make sure you have done the following
- Updated to the latest version of
blink.cmp - Searched for existing issues and documentation (try
<C-k>on https://cmp.saghen.dev)
Bug Description
Issue #2288 complained that a user's vim.lsp.config would be overridden. So the start of blink-cmp.lua does this now:
if vim.fn.has('nvim-0.11') == 1 and vim.lsp.config then
local user_caps = vim.lsp.config['*'].capabilities
vim.lsp.config('*', {
capabilities = require('blink.cmp').get_lsp_capabilities(user_caps),
})
end
This fails if vim.lsp.config['*'] is not set by the user before blink-cmp loads, because it's indexing into a nil value instead of a table.
Proposed fix: change line 2 to
local user_caps = vim.lsp.config['*'] and vim.lsp.config['*'].capabilities or {}
Relevant configuration
Happens with any config.neovim version
0.11
blink.cmp version
1.9.1
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working