rename filter to regexFilter

to prevent to redifine an builtin function
This commit is contained in:
Bastian Schroll 2016-10-03 11:50:18 +02:00
parent 76dbdc0692
commit e8e870849d
3 changed files with 4 additions and 4 deletions

View file

@ -281,8 +281,8 @@ try:
# #
try: try:
if globals.config.getboolean("BOSWatch","useRegExFilter"): if globals.config.getboolean("BOSWatch","useRegExFilter"):
from includes import filter from includes import regexFilter
filter.loadFilters() regexFilter.loadFilters()
except: except:
# It's an error, but we could work without that stuff... # It's an error, but we could work without that stuff...
logging.error("cannot load filters") logging.error("cannot load filters")

View file

@ -77,8 +77,8 @@ def processAlarm(typ, freq, data):
for pluginName, plugin in globals.pluginList.items(): for pluginName, plugin in globals.pluginList.items():
# if enabled use RegEx-filter # if enabled use RegEx-filter
if globals.config.getint("BOSWatch","useRegExFilter"): if globals.config.getint("BOSWatch","useRegExFilter"):
from includes import filter from includes import regexFilter
if filter.checkFilters(typ, data, pluginName, freq): if regexFilter.checkFilters(typ, data, pluginName, freq):
logging.debug("call Plugin: %s", pluginName) logging.debug("call Plugin: %s", pluginName)
try: try:
plugin.run(typ, freq, data) plugin.run(typ, freq, data)