From ffe690f0369dddec7930edd7a0533a597c6abc1c Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Mon, 2 Sep 2024 15:45:12 +0100 Subject: [Doc] Discourage old brain damaged method of symbols registration --- src/lua/lua_config.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/lua') diff --git a/src/lua/lua_config.c b/src/lua/lua_config.c index fc068270e..be5822c7a 100644 --- a/src/lua/lua_config.c +++ b/src/lua/lua_config.c @@ -34,7 +34,11 @@ local function foo(task) -- do something end -rspamd_config:register_symbol('SYMBOL', 1.0, foo) +rspamd_config:register_symbol{ + name = 'SYMBOL', + score = 1.0, + callback = foo +} -- Get configuration local tab = rspamd_config:get_all_opt('module') -- get table for module's options -- cgit v1.2.3