Skip to content

Commit

Permalink
Respect bufnr with codelens parser
Browse files Browse the repository at this point in the history
  • Loading branch information
cstoku committed Mar 2, 2024
1 parent c43d958 commit d11bbea
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ end
---@type TsserverProtocolHandler
function M.handler(request, _, params)
local text_document = params.textDocument
local ok, parser = pcall(ts.get_parser)
local bufnr = vim.uri_to_bufnr(text_document.uri)
local ok, parser = pcall(ts.get_parser, bufnr)

if not ok then
vim.notify_once(
Expand Down

0 comments on commit d11bbea

Please sign in to comment.