mirror of
https://github.com/ntop/ntopng.git
synced 2026-05-05 10:41:34 +00:00
Fixes attempt to index nil value
This commit is contained in:
parent
89d38def6b
commit
2bfa14152d
1 changed files with 3 additions and 0 deletions
|
|
@ -727,6 +727,9 @@ function lists_utils.reset_blacklist_url(list_name, enabled)
|
|||
if not isEmptyString(lists_metadata) then
|
||||
current_lists = json.decode(lists_metadata)
|
||||
end
|
||||
if not current_lists[list_name] then
|
||||
current_lists[list_name] = {}
|
||||
end
|
||||
current_lists[list_name].url = default_url
|
||||
ntop.setPref(METADATA_KEY, json.encode(current_lists))
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue