Fixed time string

This commit is contained in:
Myx
2023-10-15 03:56:17 +02:00
parent 2e87f14ced
commit 5c9fec4767
4 changed files with 11 additions and 8 deletions

6
bot.ts
View File

@@ -121,7 +121,7 @@ function scheduleNextJoin(){
log(randomInterval);
nextPlayBackTime = new Date(new Date().getTime() + randomInterval * 60000).toString();
nextPlayBackTime = new Date(new Date().getTime() + randomInterval * 60000).toTimeString();
const minutes = randomInterval % 60;
const hours = Math.floor(randomInterval / 60);
@@ -144,8 +144,8 @@ function log(waitTime: number){
console.log(
LoggerColors.Cyan, `
Wait time: ${waitTime} minutes,
Current time: ${currentTime.toString()},
Next join time: ${nextJoinTime.toString()},
Current time: ${currentTime.toTimeString()},
Next join time: ${nextJoinTime.toTimeString()},
Cron: ${minutes} ${hours == 0 ? '*' : hours } * * *`
);
}