Fix issue when adding new builtin category lists

This commit is contained in:
emanuele-f 2019-02-11 19:32:14 +01:00
parent 67f212b866
commit 62e2c67672

View file

@ -83,15 +83,14 @@ local function loadListsFromRedis()
end
local status = json.decode(lists_status)
local lists
local lists = {}
if isEmptyString(lists_metadata) then
-- no custom settings, use builtins
lists = table.clone(BUILTIN_LISTS)
else
if not isEmptyString(lists_metadata) then
lists = json.decode(lists_metadata)
end
lists = table.merge(BUILTIN_LISTS, lists)
if((lists == nil) or (status == nil)) then
return {}
end