fix: updating provider config (#2183)

This commit is contained in:
yetone
2025-06-07 16:34:21 +08:00
committed by GitHub
parent 687da816f9
commit a2f31bd2e2
3 changed files with 42 additions and 32 deletions

View File

@@ -1133,6 +1133,17 @@ function M.icon(string_with_icon, utf8_fallback)
end
end
function M.inherit(base, ...)
local children = { ... }
return setmetatable(base, {
__index = function(_, k)
for _, child in ipairs(children) do
if child[k] ~= nil then return child[k] end
end
end,
})
end
function M.deep_extend_with_metatable(behavior, ...)
local tables = { ... }
local base = tables[1]