mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-30 07:59:35 +00:00
Cleaned up the code from plugin_utils
This commit is contained in:
parent
f1e8091928
commit
57a85de50e
105 changed files with 620 additions and 918 deletions
|
|
@ -7,7 +7,7 @@ local alerts_api = require "alerts_api"
|
|||
local alert_consts = require("alert_consts")
|
||||
local flow_alert_keys = require "flow_alert_keys"
|
||||
|
||||
local UNEXPECTED_PLUGINS_ENABLED_CACHE_KEY = "ntopng.cache.checks.unexpected_plugins_enabled"
|
||||
local UNEXPECTED_SCRIPTS_ENABLED_CACHE_KEY = "ntopng.cache.checks.unexpected_scripts_enabled"
|
||||
|
||||
-- #################################################################
|
||||
|
||||
|
|
@ -39,10 +39,10 @@ local script = {
|
|||
-- #################################################################
|
||||
|
||||
function script.onEnable(hook, hook_config)
|
||||
-- Set a flag to indicate to the notifications system that an unexpected plugin
|
||||
-- Set a flag to indicate to the notifications system that an unexpected script
|
||||
-- has been enabled
|
||||
if isEmptyString(ntop.getCache(UNEXPECTED_PLUGINS_ENABLED_CACHE_KEY)) then
|
||||
ntop.setCache(UNEXPECTED_PLUGINS_ENABLED_CACHE_KEY, "1")
|
||||
if isEmptyString(ntop.getCache(UNEXPECTED_SCRIPTS_ENABLED_CACHE_KEY)) then
|
||||
ntop.setCache(UNEXPECTED_SCRIPTS_ENABLED_CACHE_KEY, "1")
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue