Skip to content

Commit 9b0b53b

Browse files
authored
bug: fix threshold notification (alexjustesen#2702)
1 parent 5d391b6 commit 9b0b53b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

app/Listeners/ProcessUnhealthySpeedtest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ private function notifyAppriseChannels(Result $result): void
7272
if ($benchmark['passed'] === false) {
7373
$failed[] = [
7474
'name' => ucfirst($metric),
75-
'threshold' => $benchmark['value'].' '.$benchmark['unit'],
75+
'threshold' => $benchmark['benchmark_value'].' '.$benchmark['unit'],
7676
'value' => $this->formatMetricValue($metric, $result),
7777
];
7878
}

app/Mail/UnhealthySpeedtestMail.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ private function formatBenchmark(string $metric, array $benchmark): array
6262
{
6363
$metricName = str($metric)->title();
6464
$type = str($benchmark['type'])->title();
65-
$thresholdValue = $benchmark['value'].' '.str($benchmark['unit'])->title();
65+
$thresholdValue = $benchmark['benchmark_value'].' '.str($benchmark['unit'])->title();
6666

6767
// Get the actual result value
6868
$resultValue = match ($metric) {

0 commit comments

Comments
 (0)