Change seconds to minutes

This commit is contained in:
OidaTiftla
2022-01-23 17:48:09 +01:00
parent 65fc71e485
commit 11e9eee09d
3 changed files with 4 additions and 2 deletions

View File

@@ -403,7 +403,7 @@ class Monitor extends BeanModel {
bean.important = false;
if (bean.status === DOWN && this.resendInterval > 0) {
timeSinceLastNotified = dayjs().valueOf() - (bean.lastNotifiedTime || 0);
timeSinceLastNotified = (dayjs().valueOf() - (bean.lastNotifiedTime || 0)) / 60; // divide by 60 to convert from seconds to minutes
if (timeSinceLastNotified >= this.resendInterval) {
// Send notification again, because we are still DOWN
debug(`[${this.name}] sendNotification`);