Skip to content

Commit

Permalink
fix(actions): set function name for generate.which_key (#3044)
Browse files Browse the repository at this point in the history
Using anonymous function is throwing warning "No name available for
anonymous functions" when `action_generate.which_key` is used as shown
in the docs.
  • Loading branch information
jamestrew committed Apr 10, 2024
1 parent d26b666 commit 5a701e9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lua/telescope/actions/generate.lua
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,10 @@ local action_generate = {}
---@field border_hl string: winhl of "Normal" for keymap borders (default: "TelescopePromptBorder")
---@field winblend number: pseudo-transparency of keymap hints floating window
action_generate.which_key = function(opts)
return function(prompt_bufnr)
local which_key = function(prompt_bufnr)
actions.which_key(prompt_bufnr, opts)
end
return which_key
end

action_generate.refine = function(prompt_bufnr, opts)
Expand Down

0 comments on commit 5a701e9

Please sign in to comment.