From 30eaa3fa77f30fb577e5f61bb3fed4d2680c6cfe Mon Sep 17 00:00:00 2001 From: HicaroD Date: Thu, 26 Oct 2023 10:09:25 -0300 Subject: [PATCH] fix: removing warning about `file_uri` variable not being used --- lua/telescope/builtin/__lsp.lua | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lua/telescope/builtin/__lsp.lua b/lua/telescope/builtin/__lsp.lua index c6ceae51bb..01a19912c7 100644 --- a/lua/telescope/builtin/__lsp.lua +++ b/lua/telescope/builtin/__lsp.lua @@ -200,10 +200,8 @@ local function list_or_jump(action, title, opts) elseif opts.jump_type == "vsplit" then vim.cmd "vnew" elseif opts.jump_type == "tab drop" then - local file_uri = "" - if flattened_results[1].uri ~= nil then - file_uri = flattened_results[1].uri - else + local file_uri = flattened_results[1].uri + if file_uri == nil then file_uri = flattened_results[1].targetUri end local file_path = vim.uri_to_fname(file_uri)