add or nil({}) to extend function to avoid 'expected table' error

pull/151/head
Briain O'Driscoll 2 years ago
parent 21877b4ced
commit af08b44b08

@ -169,7 +169,7 @@ local schemas = {
}
local function extend(tab1, tab2)
for _, value in ipairs(tab2) do
for _, value in ipairs(tab2 or {}) do
table.insert(tab1, value)
end
return tab1

Loading…
Cancel
Save