We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8515c37 commit 9640d0bCopy full SHA for 9640d0b
apps/language_server/lib/language_server/providers/code_action/helpers.ex
@@ -54,10 +54,10 @@ defmodule ElixirLS.LanguageServer.Providers.CodeAction.Helpers do
54
# https://microsoft.github.io/language-server-protocol/specifications/lsp/3.18/specification/#diagnostic
55
# message can be string or MarkupContent
56
# string
57
- def diagnostic_to_message(diagnostic) when is_binary(diagnostic), do: diagnostic
+ def diagnostic_to_message(%{"message" => message}) when is_binary(message), do: message
58
59
# MarkupContent
60
- def diagnostic_to_message(%{"kind" => kind, "value" => value})
+ def diagnostic_to_message(%{"message" => %{"kind" => kind, "value" => value}})
61
when kind in ["plaintext", "markdown"],
62
do: value
63
end
0 commit comments