Skip to content

Commit

Permalink
PR feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisronline committed Aug 26, 2020
1 parent 7659021 commit d5c2677
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

import { defaultsDeep, uniq, compact } from 'lodash';

import { ServiceStatusLevels } from '../../../../../src/core/server';
import {
TELEMETRY_COLLECTION_INTERVAL,
KIBANA_STATS_TYPE_MONITORING,
Expand Down Expand Up @@ -55,7 +55,7 @@ export class BulkUploader {

this.kibanaStatus = null;
this.kibanaStatusGetter$ = statusGetter$.subscribe((nextStatus) => {
this.kibanaStatus = nextStatus.level.toString();
this.kibanaStatus = nextStatus.level;
});
}

Expand Down Expand Up @@ -173,13 +173,13 @@ export class BulkUploader {
}

getConvertedKibanaStatuss() {
if (this.kibanaStatus === 'available') {
if (this.kibanaStatus === ServiceStatusLevels.available) {
return 'green';
}
if (this.kibanaStatus === 'critical') {
if (this.kibanaStatus === ServiceStatusLevels.critical) {
return 'red';
}
if (this.kibanaStatus === 'degraded') {
if (this.kibanaStatus === ServiceStatusLevels.degraded) {
return 'yellow';
}
return 'unknown';
Expand Down

0 comments on commit d5c2677

Please sign in to comment.