diff options
author | Christian Clason <c.clason@uni-graz.at> | 2021-09-17 13:35:57 +0200 |
---|---|---|
committer | Christian Clason <c.clason@uni-graz.at> | 2021-09-17 13:35:57 +0200 |
commit | 22d146760e136152b3fe72bdd7ae982f43f2751b (patch) | |
tree | d7e7c107734b8effe4949c5de20a0758c1105b36 /runtime/lua/vim/lsp/diagnostic.lua | |
parent | 3e230da90b4e20bcf25ec4bfdcb7a87e3a22f56e (diff) | |
download | rneovim-22d146760e136152b3fe72bdd7ae982f43f2751b.tar.gz rneovim-22d146760e136152b3fe72bdd7ae982f43f2751b.tar.bz2 rneovim-22d146760e136152b3fe72bdd7ae982f43f2751b.zip |
fix(diagnostic): don't convert diagnostic table twice
The recursive implementation of vim.lsp.diagnostic.get() applied
`diagnostic_vim_to_lsp` twice, and the second time gave wrong
results because of the unexpected format.
Fixes https://github.com/neovim/neovim/issues/15689
Diffstat (limited to 'runtime/lua/vim/lsp/diagnostic.lua')
-rw-r--r-- | runtime/lua/vim/lsp/diagnostic.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/runtime/lua/vim/lsp/diagnostic.lua b/runtime/lua/vim/lsp/diagnostic.lua index 48c0dd92cb..eef840bee5 100644 --- a/runtime/lua/vim/lsp/diagnostic.lua +++ b/runtime/lua/vim/lsp/diagnostic.lua @@ -265,7 +265,7 @@ function M.get(bufnr, client_id, predicate) table.insert(all_diagnostics, diagnostic) end end) - return diagnostic_vim_to_lsp(all_diagnostics) + return all_diagnostics end local namespace = M.get_namespace(client_id) |