diff options
author | Steven Barth <steven@midlink.org> | 2008-05-24 14:11:15 +0000 |
---|---|---|
committer | Steven Barth <steven@midlink.org> | 2008-05-24 14:11:15 +0000 |
commit | 427dd0bd1dcaf081b21be96d6f0e73d542dd2f08 (patch) | |
tree | 07ffe38a02af13aaab512307addf696a2a814a4d /core/src/util.lua | |
parent | f920f79b643b2a2c969228e06b4b9c5fcd097fe0 (diff) |
* Added support for first-level controllers
* Added several posix functions to ffluci.fs
* Added ffluci.util.combine
Diffstat (limited to 'core/src/util.lua')
-rw-r--r-- | core/src/util.lua | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/core/src/util.lua b/core/src/util.lua index 9e3c7f25e..c7dba3196 100644 --- a/core/src/util.lua +++ b/core/src/util.lua @@ -73,6 +73,18 @@ function clone(object, deep) end +-- Combines two or more numerically indexed tables into one +function combine(...) + local result = {} + for i, a in ipairs(arg) do + for j, v in ipairs(a) do + table.insert(result, v) + end + end + return result +end + + -- Checks whether a table has an object "value" in it function contains(table, value) for k,v in pairs(table) do |