Skip to content

Commit

Permalink
fix(hover): ignore results from previous buggers
Browse files Browse the repository at this point in the history
  • Loading branch information
mrcjkb committed Jan 14, 2024
1 parent d3f3226 commit 18bb5fe
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lua/haskell-tools/lsp/hover.lua
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,10 @@ function hover.on_hover(_, result, ctx, config)
local ht = require('haskell-tools')
config = config or {}
config.focus_id = ctx.method
if vim.api.nvim_get_current_buf() ~= ctx.bufnr then
-- Ignore result since buffer changed.
return
end
if not (result and result.contents) then
vim.notify('No information available')
return
Expand Down

0 comments on commit 18bb5fe

Please sign in to comment.