fix: escape newlines in code action title (#1012)

This commit is contained in:
Dhruv Manilawala
2021-08-05 01:46:18 +05:30
committed by GitHub
parent ca195e32e0
commit aa7c13ea36

View File

@@ -165,7 +165,7 @@ lsp.code_actions = function(opts)
for _, result in pairs(response.result) do
local entry = {
idx = idx,
command_title = result.title,
command_title = result.title:gsub("\r\n", "\\r\\n"):gsub("\n", "\\n"),
client_name = client and client.name or "",
command = result,
}