cleanup
This commit is contained in:
parent
1e926024ce
commit
22526c0386
@ -216,11 +216,11 @@ function Gladdy:DeleteUnknownOptions(tbl, refTbl, str)
|
|||||||
end
|
end
|
||||||
for k,v in pairs(tbl) do
|
for k,v in pairs(tbl) do
|
||||||
if refTbl[k] == nil then
|
if refTbl[k] == nil then
|
||||||
--Gladdy:Print("SavedVariable deleted:", str .. "." .. k, "not found!")
|
Gladdy:Debug("INFO", "SavedVariable deleted:", str .. "." .. k, "not found!")
|
||||||
tbl[k] = nil
|
tbl[k] = nil
|
||||||
else
|
else
|
||||||
if type(v) ~= type(refTbl[k]) then
|
if type(v) ~= type(refTbl[k]) then
|
||||||
--Gladdy:Print("SavedVariable deleted:", str .. "." .. k, "type error!", "Expected", type(refTbl[k]), "but found", type(v))
|
Gladdy:Debug("INFO", "SavedVariable deleted:", str .. "." .. k, "type error!", "Expected", type(refTbl[k]), "but found", type(v))
|
||||||
tbl[k] = nil
|
tbl[k] = nil
|
||||||
elseif type(v) == "table" then
|
elseif type(v) == "table" then
|
||||||
Gladdy:DeleteUnknownOptions(v, refTbl[k], str .. "." .. k)
|
Gladdy:DeleteUnknownOptions(v, refTbl[k], str .. "." .. k)
|
||||||
|
Loading…
Reference in New Issue
Block a user