Safe check

This commit is contained in:
soulgalore 2020-12-21 04:26:09 +01:00
parent d5466244d4
commit 536097558d
1 changed files with 1 additions and 1 deletions

View File

@ -127,7 +127,7 @@ module.exports = function(
const limitMetric = metrics[slackOptions.limitMetric];
// if we failed with a run, we don't have the metric and just make it dangerous
if (limitMetric === undefined) {
if (limitMetric === undefined || (limitMetric && !limitMetric.metric)) {
color = 'danger';
} else {
if (slackOptions.limitMetric === 'coachScore') {