From b058b84fb3dfdea1214155146e0d7526b7c72f61 Mon Sep 17 00:00:00 2001 From: juakotorres Date: Sun, 15 Mar 2020 00:44:50 -0300 Subject: [PATCH] holi --- bot.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bot.js b/bot.js index 1035c6f..c492710 100644 --- a/bot.js +++ b/bot.js @@ -73,12 +73,12 @@ bot.onText(/\/cuandoLaRevision/, (msg, match) => { } else { if (date.getTime() > now.getTime()) { const diffTime = Math.abs(date - now); - const diffDays = Math.ceil(diffTime / (1000 * 60 * 60 * 24)) - 1; + const diffDays = Math.ceil(diffTime / (1000 * 60 * 60 * 24)); bot.sendMessage(chatId, "Wait prrito todavía te faltan " + diffDays + " días.").then(() => {}); } else { const diffTime = Math.abs(now - date); - const diffDays = Math.ceil(diffTime / (1000 * 60 * 60 * 24)) - 1; + const diffDays = Math.ceil(diffTime / (1000 * 60 * 60 * 24)); const diffHrs = Math.floor((diffTime % 86400000) / 3600000); // hours const diffMinutes = Math.round(((diffTime % 86400000) % 3600000) / 60000); // minutes