fix: Bug with nil action error (#1340)

only affects 0.5.1
This commit is contained in:
Rafael Delboni
2021-10-12 18:17:42 -03:00
committed by GitHub
parent c19eae901c
commit b5c63c6329

View File

@@ -314,7 +314,11 @@ lsp.code_actions = function(opts)
vim.notify(resolved_err.code .. ": " .. resolved_err.message, vim.log.levels.ERROR) vim.notify(resolved_err.code .. ": " .. resolved_err.message, vim.log.levels.ERROR)
return return
end end
execute_action(transform_action(resolved_action)) if resolved_action then
execute_action(transform_action(resolved_action))
else
execute_action(transform_action(action))
end
end) end)
else else
execute_action(transform_action(action)) execute_action(transform_action(action))