Fixes alerts of different licenses loaded

This commit is contained in:
Matteo Biscosi 2023-08-02 15:17:11 +00:00
parent 09db773f07
commit bf63b51ce5
2 changed files with 5 additions and 2 deletions

View file

@ -721,9 +721,12 @@ end
local function loadAndCheckScript(mod_fname, full_path, script, script_type, subdir, return_all, scripts_filter,
hook_filter)
local setup_ok = true
-- Recheck the edition as the demo mode may expire
if script then
if (script.setup and script.setup() == false) then
return (nil)
end
if (script.edition == "pro" and not ntop.isPro()) or
((script.edition == "enterprise_l" or script.edition == "enterprise_m") and not ntop.isEnterpriseM()) or
(script.edition == "enterprise_l" and not ntop.isEnterpriseL()) then