From 0e706e725188b35aac6ec68968b2b5a65440fccb Mon Sep 17 00:00:00 2001 From: ChomeNS Date: Fri, 30 Dec 2022 20:47:17 +0700 Subject: [PATCH] ops --- commands/time.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/commands/time.js b/commands/time.js index 0b96bfa..644f502 100644 --- a/commands/time.js +++ b/commands/time.js @@ -12,9 +12,9 @@ module.exports = { const momented = moment().tz(timezone).format(format) const component = [{ text: 'The current date and time for the timezone ', color: 'white' }, { text: timezone, color: 'aqua' }, { text: ' is: ', color: 'white' }, { text: momented, color: 'green' }] if (momented === moment().format(format) && - (timezone.toLowerCase() === 'asia/bangkok' || - timezone.toLowerCase() === 'utc' || - timezone.toLowerCase() === 'america/new_york' + (timezone.toLowerCase() !== 'asia/bangkok' || + timezone.toLowerCase() !== 'utc' || + timezone.toLowerCase() !== 'america/new_york' ) ) { throw new SyntaxError('Invalid timezone') @@ -28,9 +28,9 @@ module.exports = { const momented = moment().tz(timezone).format(format) const description = `The current date and time for the timezone ${timezone} is: ${momented}` if (momented === moment().format(format) && - (timezone.toLowerCase() === 'asia/bangkok' || - timezone.toLowerCase() === 'utc' || - timezone.toLowerCase() === 'america/new_york' + (timezone.toLowerCase() !== 'asia/bangkok' || + timezone.toLowerCase() !== 'utc' || + timezone.toLowerCase() !== 'america/new_york' ) ) { throw new SyntaxError('Invalid timezone')