Skip to content

Commit

Permalink
fix(lsp.definitions): compare file uri with targetUri (nvim-telesco…
Browse files Browse the repository at this point in the history
  • Loading branch information
Akmadan23 authored and abelmul committed Jun 6, 2023
1 parent 9add162 commit f9ee099
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lua/telescope/builtin/__lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,8 @@ local function list_or_jump(action, title, opts)
if #flattened_results == 0 then
return
elseif #flattened_results == 1 and opts.jump_type ~= "never" then
if params.textDocument.uri ~= flattened_results[1].uri then
local uri = params.textDocument.uri
if uri ~= flattened_results[1].uri and uri ~= flattened_results[1].targetUri then
if opts.jump_type == "tab" then
vim.cmd "tabedit"
elseif opts.jump_type == "split" then
Expand Down

0 comments on commit f9ee099

Please sign in to comment.