diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-07-14 10:37:28 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-07-14 10:37:28 +0100 |
commit | 36ad4a3924ef58570eda1a19e03ec562298ed58a (patch) | |
tree | bb4e3fcde8899e90a81a5420520150d5ef1db95e | |
parent | e3e7e1bb8fe7369f27da0d2348d423d919c766b2 (diff) | |
download | rspamd-36ad4a3924ef58570eda1a19e03ec562298ed58a.tar.gz rspamd-36ad4a3924ef58570eda1a19e03ec562298ed58a.zip |
[Minor] Fix custom keyword parsing
-rw-r--r-- | src/plugins/lua/ratelimit.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/lua/ratelimit.lua b/src/plugins/lua/ratelimit.lua index a84103ff9..7ab688ebf 100644 --- a/src/plugins/lua/ratelimit.lua +++ b/src/plugins/lua/ratelimit.lua @@ -443,9 +443,10 @@ local function ratelimit_cb(task) end for k, hdl in pairs(settings.custom_keywords or E) do - local ret, redis_key, bucket = pcall(hdl(task)) + local ret, redis_key, bd = pcall(hdl, task) if ret then + local bucket = parse_limit(k, bd) prefixes[redis_key] = make_prefix(redis_key, k, bucket) nprefixes = nprefixes + 1 else |