process.env.NODE_ENV === 'development'

This commit is contained in:
Sefinek 2024-10-10 07:20:30 +02:00
parent 9981a2991d
commit a6c7d26bd5

View file

@ -146,7 +146,7 @@ const reportIP = async (event, country, hostname, endpoint, userAgent, cycleErro
const minutesAgo = Math.floor((timeDifference % (1000 * 60 * 60)) / (1000 * 60)); const minutesAgo = Math.floor((timeDifference % (1000 * 60 * 60)) / (1000 * 60));
const secondsAgo = Math.floor((timeDifference % (1000 * 60)) / 1000); const secondsAgo = Math.floor((timeDifference % (1000 * 60)) / 1000);
log('log', `${ip} was ${reason} ${hoursAgo}h ${minutesAgo}m ${secondsAgo}s ago. Skipping...`); if (process.env.NODE_ENV === 'development') log('log', `${ip} was ${reason} ${hoursAgo}h ${minutesAgo}m ${secondsAgo}s ago. Skipping...`);
cycleSkippedCount++; cycleSkippedCount++;
continue; continue;
} }