summaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorCarsten Rosenberg <c.rosenberg@heinlein-support.de>2019-01-13 16:05:13 +0100
committerCarsten Rosenberg <c.rosenberg@heinlein-support.de>2019-01-13 16:05:13 +0100
commitd68a5f42a33d8830d268c2cc581469fa0381fa6c (patch)
tree9a9727168693a48583fba1bcbf4d8a0af3ba25fb /src/plugins
parent92ec1c97019c4a5547c115a90e00b257399a8a47 (diff)
downloadrspamd-d68a5f42a33d8830d268c2cc581469fa0381fa6c.tar.gz
rspamd-d68a5f42a33d8830d268c2cc581469fa0381fa6c.zip
[Fix] lua_scanners - fix luacheck
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/lua/antivirus.lua3
-rw-r--r--src/plugins/lua/external_services.lua6
2 files changed, 4 insertions, 5 deletions
diff --git a/src/plugins/lua/antivirus.lua b/src/plugins/lua/antivirus.lua
index 0515e3376..5ce6dfe06 100644
--- a/src/plugins/lua/antivirus.lua
+++ b/src/plugins/lua/antivirus.lua
@@ -15,7 +15,6 @@ limitations under the License.
]] --
local rspamd_logger = require "rspamd_logger"
-local rspamd_regexp = require "rspamd_regexp"
local lua_util = require "lua_util"
local fun = require "fun"
local lua_antivirus = require("lua_scanners").filter('antivirus')
@@ -108,7 +107,7 @@ local function add_antivirus_rule(sym, opts)
return nil
end
- rule.patterns = common.create_regex_table(task, opts.patterns or {})
+ rule.patterns = common.create_regex_table(opts.patterns or {})
if opts['whitelist'] then
rule['whitelist'] = rspamd_config:add_hash_map(opts['whitelist'])
diff --git a/src/plugins/lua/external_services.lua b/src/plugins/lua/external_services.lua
index 038142da5..fb7aef709 100644
--- a/src/plugins/lua/external_services.lua
+++ b/src/plugins/lua/external_services.lua
@@ -147,11 +147,11 @@ local function add_scanner_rule(sym, opts)
rule.scan_all_mime_parts = false
end
- rule.patterns = common.create_regex_table(task, opts.patterns or {})
+ rule.patterns = common.create_regex_table(opts.patterns or {})
- rule.mime_parts_filter_regex = common.create_regex_table(task, opts.mime_parts_filter_regex or {})
+ rule.mime_parts_filter_regex = common.create_regex_table(opts.mime_parts_filter_regex or {})
- rule.mime_parts_filter_ext = common.create_regex_table(task, opts.mime_parts_filter_ext or {})
+ rule.mime_parts_filter_ext = common.create_regex_table(opts.mime_parts_filter_ext or {})
if opts['whitelist'] then
rule['whitelist'] = rspamd_config:add_hash_map(opts['whitelist'])