web/admin: fix outpost/ldap charts when no healthy objects exist

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer
2021-06-09 09:31:30 +02:00
parent 66e3bc6b58
commit de11181890
3 changed files with 9 additions and 6 deletions

View File

@ -57,7 +57,7 @@ export class LDAPSyncStatusChart extends AKChart<LDAPSyncStats> {
}));
this.centerText = sources.pagination.count.toString();
return {
healthy: healthy === 0 ? -1 : healthy,
healthy: sources.pagination.count === 0 ? -1 : healthy,
failed,
unsynced
};

View File

@ -53,7 +53,7 @@ export class OutpostStatusChart extends AKChart<OutpostStats> {
}));
this.centerText = outposts.pagination.count.toString();
return {
healthy: healthy === 0 ? -1 : healthy,
healthy: outposts.pagination.count === 0 ? -1 : healthy,
outdated,
unhealthy
};