From f5715207c9491b30a69360d3489536190ad5aef5 Mon Sep 17 00:00:00 2001 From: toppair Date: Fri, 22 Apr 2022 11:32:53 +0200 Subject: [PATCH] Provide offset_encoding argument --- lua/symbols-outline/rename.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lua/symbols-outline/rename.lua b/lua/symbols-outline/rename.lua index 25a06f0..8bc5044 100644 --- a/lua/symbols-outline/rename.lua +++ b/lua/symbols-outline/rename.lua @@ -29,9 +29,10 @@ function M.rename() params.newName = new_name - buf_request(params.bufnr, 'textDocument/rename', params, function(_, result) + buf_request(params.bufnr, 'textDocument/rename', params, function(_, result, ctx) if result ~= nil then - vim.lsp.util.apply_workspace_edit(result) + local client = vim.lsp.get_client_by_id(ctx.client_id) + vim.lsp.util.apply_workspace_edit(result, client.offset_encoding) end end) end