task:insert_result(options['symbol'] .. '_FAIL', 1, string.format('%s:%s', req_name, dns_err))
return
end
- if not (results and results[1]) then
+ if not (results or results[1]) then
rspamd_logger.infox(task, 'cannot query ip %s on %s: no results',
req_name, serv)
return
flags = 'empty',
score = 0,
})
+ rspamd_config:register_symbol{
+ name = options['symbol'] .. '_FAIL',
+ parent = id,
+ type = 'virtual',
+ flags = 'nostat',
+ score = 0,
+ }
end
else
lua_util.disable_module(N, 'config')