diff --git a/src/core/isProxy.js b/src/core/isProxy.js index 4d61e88..ba72d1b 100644 --- a/src/core/isProxy.js +++ b/src/core/isProxy.js @@ -116,12 +116,16 @@ async function dummy() { } async function saveIPInfo(ip, isProxy, info) { - const whoisData = await whois(ip); - IPInfo.upsert({ - ...whoisData, - isProxy, - pcheck: info, - }); + try { + const whoisData = await whois(ip); + IPInfo.upsert({ + ...whoisData, + isProxy, + pcheck: info, + }); + } catch (error) { + logger.error(`Error whois for ${ip}: ${error.message}`); + } } /*