diff --git a/cf-lib/util/table.lua b/cf-lib/util/table.lua index aa92228..3f829a0 100644 --- a/cf-lib/util/table.lua +++ b/cf-lib/util/table.lua @@ -68,4 +68,19 @@ function table.filter(target, predicate) end end return result +end + +--- Concatenates two tables into a new table. +--- @param table1 table The first table +--- @param table2 table The second table +--- @return table The concatenated table +function table.concat(table1, table2) + local result = {} + for _, v in pairs(table1) do + table.insert(result, v) + end + for _, v in pairs(table2) do + table.insert(result, v) + end + return result end \ No newline at end of file