Safegaurding alerts in case they come back undefined (#85108)

This commit is contained in:
igoristic 2020-12-07 11:24:44 -05:00 committed by GitHub
parent 2466dd634a
commit 008c6a0e19
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -168,7 +168,7 @@ export class MonitoringViewBaseController {
$scope.$apply(() => {
this._isDataInitialized = true; // render will replace loading screen with the react component
$scope.pageData = this.data = pageData.value; // update the view's data with the fetch result
$scope.alerts = this.alerts = alerts.value || {};
$scope.alerts = this.alerts = alerts && alerts.value ? alerts.value : {};
});
});
};