We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1f51e3b commit f019e14Copy full SHA for f019e14
src/View/Components/Metrics.php
@@ -25,12 +25,10 @@ public function render(): View
25
26
// Convert each metric point to Chart.js format (x, y)
27
$metrics->each(function ($metric) {
28
- $metric->metricPoints->transform(function ($point) {
29
- return [
30
- 'x' => $point->created_at->toIso8601String(),
31
- 'y' => $point->value,
32
- ];
33
- });
+ $metric->metricPoints->transform(fn ($point) => [
+ 'x' => $point->created_at->toIso8601String(),
+ 'y' => $point->value,
+ ]);
34
});
35
36
return view('cachet::components.metrics', [
0 commit comments