]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Replies: Fix the case when we cannot find hash in Redis
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 25 Mar 2019 14:38:42 +0000 (14:38 +0000)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 25 Mar 2019 14:38:42 +0000 (14:38 +0000)
src/plugins/lua/replies.lua

index 48c760eede8abf30518bbcfd7a47c14a1912e316..dcba6cc81656e1c19600179bfbdd87f930b96af7 100644 (file)
@@ -88,7 +88,7 @@ local function replies_check(task)
       rspamd_logger.errx(task, 'redis_get_cb received error: %1', err)
       return
     end
-    if data and check_recipient(data) then
+    if data and type(data) == 'string' and check_recipient(data) then
       -- Hash was found
       task:insert_result(settings['symbol'], 1.0)
       if settings['action'] ~= nil then