fix: do not ignore mappings from setup() when attach_mappings provided (#2613)

(cherry picked from commit 597a3cc889)
This commit is contained in:
Andrii Berezhynskyi
2023-07-21 13:28:26 +00:00
committed by Simon Hauser
parent 6bc7bd7c60
commit dc4ea2cab4
+8
View File
@@ -530,6 +530,14 @@ local apply_config = function(mod)
end
end
if defaults.attach_mappings and opts.attach_mappings then
local opts_attach = opts.attach_mappings
opts.attach_mappings = function(prompt_bufnr, map)
defaults.attach_mappings(prompt_bufnr, map)
return opts_attach(prompt_bufnr, map)
end
end
v(vim.tbl_extend("force", defaults, opts))
end
end