1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2024-12-13 19:50:31 +00:00

Allow Number and Table

This commit is contained in:
Wilma456 2017-06-29 17:58:53 +02:00 committed by GitHub
parent 845e1b633d
commit 5e244273c2

View File

@ -108,14 +108,9 @@ end
local function tabulateCommon( bPaged, ... )
local tAll = { ... }
for i=1,#tAll,2 do
if type( tAll[i] ) ~= "number" then
error( "bad argument #"..i.." (expected number, got " .. type( tAll[i] ) .. ")", 3 )
end
end
for i=2,#tAll,2 do
if type( tAll[i] ) ~= "table" then
error( "bad argument #"..i.." (expected table, got " .. type( tAll[i] ) .. ")", 3 )
for k,v in ipairs( tAll ) do
if type( v ) ~= "number" and type( v ) ~= "table" then
error( "bad argument #"..k.." (expected number/table, got " .. type( v ) .. ")", 3 )
end
end