diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-06-26 13:24:03 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-06-26 13:24:03 +0100 |
commit | 4ac44f3b22819c2046b7820721e8f7ddd774b505 (patch) | |
tree | 6fa8ebf4715c1c365c92031cda44069ebf0f23eb /lualib | |
parent | d4607205f94fdebc34a87c8e2e3ac48c292bafda (diff) | |
download | rspamd-4ac44f3b22819c2046b7820721e8f7ddd774b505.tar.gz rspamd-4ac44f3b22819c2046b7820721e8f7ddd774b505.zip |
[Fix] Fix redis sentinel support
Issue: #2796
Diffstat (limited to 'lualib')
-rw-r--r-- | lualib/lua_redis.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lualib/lua_redis.lua b/lualib/lua_redis.lua index 941ac383a..37cdb7b6a 100644 --- a/lualib/lua_redis.lua +++ b/lualib/lua_redis.lua @@ -230,7 +230,7 @@ local function add_redis_sentinels(params) params.sentinel_master_maxerrors = 2 -- Maximum number of errors before rechecking end - rspamd_config:add_on_load(function(cfg, ev_base, worker) + rspamd_config:add_on_load(function(_, ev_base, worker) local initialised = false if worker:is_scanner() then rspamd_config:add_periodic(ev_base, 0.0, function() @@ -304,8 +304,8 @@ local function process_redis_opts(options, redis_params) redis_params['password'] = options['password'] end - if not redis_params.sentinel and options.sentinel then - redis_params.sentinel = options.sentinel + if not redis_params.sentinels and options.sentinels then + redis_params.sentinels = options.sentinels end end |