]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Fix cdb usage
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Fri, 21 Jun 2019 13:18:05 +0000 (14:18 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Sat, 22 Jun 2019 09:57:29 +0000 (10:57 +0100)
src/plugins/lua/multimap.lua

index d9fc0b449f361d837c188f8145050c2e6d0fa833..5db8d4680a82233f3485929ff66bbd1f42caacaa 100644 (file)
@@ -22,7 +22,6 @@ end
 
 local rules = {}
 local rspamd_logger = require "rspamd_logger"
-local cdb = require "rspamd_cdb"
 local util = require "rspamd_util"
 local regexp = require "rspamd_regexp"
 local rspamd_expression = require "rspamd_expression"
@@ -401,6 +400,7 @@ local function multimap_callback(task, rule)
 
     if r['cdb'] then
       if type(r.cdb) == 'string' then
+        local rspamd_cdb = require "rspamd_cdb"
         local cdb = rspamd_cdb.create(r.cdb, task:get_ev_base())
 
         if not cdb then