mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-30 07:59:35 +00:00
Avoids unnecessary executions of flow user script external_alert_check.lua
Fixes #4080
This commit is contained in:
parent
97efebb0ba
commit
9e5e63e28f
6 changed files with 31 additions and 1 deletions
|
|
@ -482,6 +482,11 @@ local function loadAndCheckScript(mod_fname, full_path, plugin, script_type, sub
|
|||
return(nil)
|
||||
end
|
||||
|
||||
if((not return_all) and user_script.external_alerts_only and (not interface.hasExternalAlerts())) then
|
||||
traceError(TRACE_DEBUG, TRACE_CONSOLE, string.format("Skipping module '%s' for interface with no external alerts", mod_fname))
|
||||
return(nil)
|
||||
end
|
||||
|
||||
if((not return_all) and ((user_script.nedge_exclude and ntop.isnEdge()) or (user_script.nedge_only and (not ntop.isnEdge())))) then
|
||||
return(nil)
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue