Skip to content

Commit 086a391

Browse files
mehaltercseickel
andauthored
fix: desc no longer being filtered out of mappings (#1206)
Co-authored-by: cseickel <cseickel@gmail.com>
1 parent dcef81d commit 086a391

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lua/neo-tree/ui/renderer.lua

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -824,7 +824,7 @@ local set_buffer_mappings = function(state)
824824
local desc
825825
if type(func) == "table" then
826826
for key, value in pairs(func) do
827-
if key ~= "command" and key ~= 1 and key ~= "config" and key ~= "desc" then
827+
if key ~= "command" and key ~= 1 and key ~= "config" then
828828
map_options[key] = value
829829
end
830830
end
@@ -834,6 +834,7 @@ local set_buffer_mappings = function(state)
834834
end
835835
if type(func) == "string" then
836836
resolved_mappings[cmd] = { text = func }
837+
map_options.desc = map_options.desc or func
837838
vfunc = state.commands[func .. "_visual"]
838839
func = state.commands[func]
839840
elseif type(func) == "function" then

0 commit comments

Comments
 (0)