mirror of
https://github.com/folke/lazy.nvim.git
synced 2025-06-28 03:24:13 +00:00
feat: cleanup keys/cmd handlers when loading a plugin
This commit is contained in:
parent
c98e722fa4
commit
3f517abfa4
6 changed files with 154 additions and 99 deletions
|
@ -127,7 +127,7 @@ function Spec:merge(old, new)
|
|||
for k, v in pairs(new) do
|
||||
if k == "_" then
|
||||
elseif old[k] ~= nil and old[k] ~= v then
|
||||
if Handler.handlers[k] then
|
||||
if Handler.types[k] then
|
||||
local values = type(v) == "string" and { v } or v
|
||||
vim.list_extend(values, type(old[k]) == "string" and { old[k] } or old[k])
|
||||
---@diagnostic disable-next-line: no-unknown
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue