]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
[Minor] Replies: Use milliseconds resolution for expiration
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Fri, 24 Apr 2020 11:57:42 +0000 (12:57 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Fri, 24 Apr 2020 11:57:42 +0000 (12:57 +0100)
src/plugins/lua/replies.lua

index 6c3459b4f37ced88129eb5fa5fcbd8d08299c33e..330049464f0665c0e69689228f2b1402204b466a 100644 (file)
@@ -158,8 +158,8 @@ local function replies_set(task)
         key, -- hash key
         true, -- is write
         redis_set_cb, --callback
-        'SETEX', -- command
-        {key, tostring(math.floor(settings['expire'])), value:lower()} -- arguments
+        'PSETEX', -- command
+        {key, tostring(math.floor(settings['expire'] * 1000)), value:lower()} -- arguments
     )
     if not ret then
       rspamd_logger.errx(task, "redis request wasn't scheduled")