From a87805a9445f280ca71da322c4b32cf357744511 Mon Sep 17 00:00:00 2001 From: Elias Fleckenstein Date: Tue, 23 Jun 2020 17:43:47 +0200 Subject: test --- builtin/common/misc_helpers.lua | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'builtin/common/misc_helpers.lua') diff --git a/builtin/common/misc_helpers.lua b/builtin/common/misc_helpers.lua index 715f89bc4..c904bccfc 100644 --- a/builtin/common/misc_helpers.lua +++ b/builtin/common/misc_helpers.lua @@ -519,6 +519,16 @@ function table.shuffle(t, from, to, random) end end +function table.combine(t, other) + other = other or {} + for k, v in pairs(other) do + if type(v) == "table" and type(t[k]) == "table" then + table.combine(t[k], v) + else + t[k] = v + end + end +end -------------------------------------------------------------------------------- -- mainmenu only functions -- cgit v1.2.3