nvim-lua / lsp-status.nvim

Utility functions for getting diagnostic status and progress messages from LSP servers, for use in the Neovim statusline
MIT License
621 stars 41 forks source link

fix exception when attempt to concatenate a nil value #80

Closed jdssl closed 2 years ago

jdssl commented 2 years ago

I'm receiving the stack error by the rust analyzer

Error executing vim.schedule lua callback: ...vim/plugged/lsp-status.nvim/lua/lsp-status/messaging.lua:38:
 attempt to concatenate a nil value
stack traceback:
        ...vim/plugged/lsp-status.nvim/lua/lsp-status/messaging.lua:38: in function 'fn'
        ...fig/nvim/plugged/lsp-status.nvim/lua/lsp-status/util.lua:71: in function 'handler'
        ...l/Cellar/neovim/0.7.2/share/nvim/runtime/lua/vim/lsp.lua:796: in function ''
        vim/_editor.lua: in function <vim/_editor.lua:0>

Other users also received the same error: #79 A simple way to solve these problems in my opinion would be to check if the value is different from the nil.

@tjdevries help us!

Fixes #79