]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Fix some logging in antivirus module 1170/head
authorAndrew Lewis <nerf@judo.za.org>
Thu, 24 Nov 2016 08:01:48 +0000 (10:01 +0200)
committerAndrew Lewis <nerf@judo.za.org>
Thu, 24 Nov 2016 08:02:12 +0000 (10:02 +0200)
src/plugins/lua/antivirus.lua

index 6060b0e8967e0f33faa263dc04715e052b2dc4fa..87ebcf99c995413fbc1e6548b14cd3f5f83798fc 100644 (file)
@@ -194,7 +194,9 @@ local function check_av_cache(task, rule, fn)
         yield_result(task, rule, data)
       end
     else
-      rspamd_logger.errx(task, 'Got error checking cache: %1', err)
+      if err then
+        rspamd_logger.errx(task, 'Got error checking cache: %1', err)
+      end
       fn()
     end
   end