aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@rspamd.com>2023-07-05 21:33:36 +0100
committerVsevolod Stakhov <vsevolod@rspamd.com>2023-07-05 21:33:36 +0100
commit5d1c4e0143c4b3ee764448a27c28fd6e6a5b0035 (patch)
tree5acaf8399ec8f950870c6272c9c7fa5ef33a023b
parent06f52fae3a0e57ee8d01aaa974139f3b31bf296c (diff)
downloadrspamd-5d1c4e0143c4b3ee764448a27c28fd6e6a5b0035.tar.gz
rspamd-5d1c4e0143c4b3ee764448a27c28fd6e6a5b0035.zip
[Minor] Fix fuzzy_unlearn_handler when a flag is specified
Issue: #4531
-rw-r--r--src/plugins/fuzzy_check.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/fuzzy_check.c b/src/plugins/fuzzy_check.c
index fd8e56cce..8dff7a6c9 100644
--- a/src/plugins/fuzzy_check.c
+++ b/src/plugins/fuzzy_check.c
@@ -3867,7 +3867,7 @@ fuzzy_lua_unlearn_handler (lua_State *L)
struct fuzzy_ctx *fuzzy_module_ctx = fuzzy_get_context (task->cfg);
if (lua_type (L, 2) == LUA_TNUMBER) {
- flag = lua_tonumber (L, 1);
+ flag = lua_tointeger (L, 2);
}
else if (lua_type (L, 2) == LUA_TSTRING) {
struct fuzzy_rule *rule;