From 257e3d227fd29ad95a2f644ccbffac46c563abdd Mon Sep 17 00:00:00 2001 From: xdavidwu Date: Mon, 26 Jul 2021 15:09:03 +0800 Subject: [PATCH] view: use user-facing title if exists --- app/Http/Controllers/UptimeController.php | 2 +- resources/views/uptime.blade.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Http/Controllers/UptimeController.php b/app/Http/Controllers/UptimeController.php index d7c3bbf..e919ff6 100644 --- a/app/Http/Controllers/UptimeController.php +++ b/app/Http/Controllers/UptimeController.php @@ -49,7 +49,7 @@ class UptimeController extends Controller } $data[] = [ - 'description' => $probe->describe(), + 'title' => $instance->title ?? $probe->describe(), 'logs' => $logs, ]; } diff --git a/resources/views/uptime.blade.php b/resources/views/uptime.blade.php index f7852ab..25c855c 100644 --- a/resources/views/uptime.blade.php +++ b/resources/views/uptime.blade.php @@ -64,7 +64,7 @@ @foreach ($data as $instance)
- {{ $instance['description'] }} + {{ $instance['title'] }}
{{ $instance['logs'][0]['from'] }}
-- 2.45.2