mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
feat(util): add array.Append helper
This commit is contained in:
@@ -73,4 +73,11 @@ function util.tableSize(T)
|
||||
return count
|
||||
end
|
||||
|
||||
-- append all elements from t2 into t1
|
||||
function util.arrayAppend(t1, t2)
|
||||
for _,v in ipairs(t2) do
|
||||
table.insert(t1, v)
|
||||
end
|
||||
end
|
||||
|
||||
return util
|
||||
|
||||
Reference in New Issue
Block a user