From: Dmitriy Alekseev <1865999+dragoangel@users.noreply.github.com> Date: Mon, 14 Oct 2024 12:35:24 +0000 (+0200) Subject: add missing change in configured state when no update is needed on index_policy X-Git-Tag: 3.11.0~33^2~22 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=28b772738c09661bb9845cb7330c2381eb143404;p=thirdparty%2Frspamd.git add missing change in configured state when no update is needed on index_policy --- diff --git a/src/plugins/lua/elastic.lua b/src/plugins/lua/elastic.lua index b2c6d36ba1..b117d6e4c7 100644 --- a/src/plugins/lua/elastic.lua +++ b/src/plugins/lua/elastic.lua @@ -823,7 +823,10 @@ local function get_index_policy(cfg, ev_base, upstream, host, policy_url, index_ update_needed = true end end - if update_needed then + if not update_needed then + rspamd_logger.infox(rspamd_config, 'elastic index policy is up-to-date') + states['index_policy']['configured'] = true + else if detected_distro['name'] == 'elastic' then put_index_policy(cfg, ev_base, upstream, host, policy_url, index_policy_json) elseif detected_distro['name'] == 'opensearch' then