diff --git a/src/commands/score.ts b/src/commands/score.ts index 2587906..d829658 100644 --- a/src/commands/score.ts +++ b/src/commands/score.ts @@ -113,8 +113,10 @@ export default class Score extends Command { inqs.forEach((inq) => { const testDate = (new Date(new Date(inq.date).setHours(1460))); // eslint-disable-next-line no-useless-escape - if (testDate > new Date()) desc += `${inq.iid ? `__[${inq.iid}]__\n` : ''}**Department/Service:** ${inq.name.replace(/\*/gmi, '')}\n**Reason:** ${inq.reason}\n**Date:** ${inq.date.toLocaleString('en-us')} ET\n**Expires:** ${moment(testDate).calendar()}\n\n`; - inqAdded++; + if (testDate > new Date()) { + desc += `${inq.iid ? `__[${inq.iid}]__\n` : ''}**Department/Service:** ${inq.name.replace(/\*/gmi, '')}\n**Reason:** ${inq.reason}\n**Date:** ${inq.date.toLocaleString('en-us')}\n**Expires:** ${moment(testDate).calendar()}\n\n`; + inqAdded++; + } }); if (inqAdded <= 0) desc = ''; if (desc.length >= 1900) {