commit 3d8f5c5: [Minor] Neural: Another fix in saving profile

Vsevolod Stakhov vsevolod at highsecure.ru
Mon Jul 8 09:49:03 UTC 2019


Author: Vsevolod Stakhov
Date: 2019-07-08 10:47:39 +0100
URL: https://github.com/rspamd/rspamd/commit/3d8f5c5e7f4ee08aa033805313fe9b5585a2d4fa (HEAD -> master)

[Minor] Neural: Another fix in saving profile

---
 src/plugins/lua/neural.lua | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/plugins/lua/neural.lua b/src/plugins/lua/neural.lua
index 10c1eadd4..7b6c2fa5f 100644
--- a/src/plugins/lua/neural.lua
+++ b/src/plugins/lua/neural.lua
@@ -285,7 +285,7 @@ local function new_ann_profile(task, rule, set, version)
       true, -- is write
       add_cb, --callback
       'ZADD', -- command
-      {set.prefix, tostring(rspamd_util.get_time()), new_ann_profile}
+      {set.prefix, tostring(rspamd_util.get_time()), profile_serialized}
   )
 
   return profile
@@ -785,7 +785,7 @@ local function load_new_ann(rule, ev_base, set, profile, min_diff)
               true, -- is write
               rank_cb, --callback
               'ZADD', -- command
-              {set.prefix, tostring(rspamd_util.get_time()), new_ann_profile}
+              {set.prefix, tostring(rspamd_util.get_time()), profile_serialized}
           )
           rspamd_logger.infox(rspamd_config, 'loaded ANN for %s from %s; %s bytes compressed; version=%s',
               rule.prefix .. ':' .. set.name, ann_key, #ann_data, profile.version)


More information about the Commits mailing list