Skip to content

Commit 0cc7817

Browse files
committed
Fixed a minor bug, dates should now work in prom.
1 parent e2f81cb commit 0cc7817

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

src/health-check.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -278,7 +278,8 @@ class HealthCheck {
278278
service.status.last_unhealthy = process.hrtime.bigint();
279279
}
280280
}
281-
await this.stats.updateService(service.name, service.status);
281+
282+
this.stats.updateService(service.name, service.status);
282283

283284
await this.alerts.alert(service);
284285
service.status.last_status = service.status.up;

src/misc/stats.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ class Stats {
77
for (var i = 0; i < this.services.length; i++) {
88
if (this.services[i].name == name) {
99
this.services[i].status = status;
10-
this.services.date = Date.now();
10+
this.services[i].date = Date.now();
1111
return;
1212
}
1313
}

0 commit comments

Comments
 (0)