From 3004310194efd089325e7c5eb21165d210a07faf Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 31 Jul 2026 11:48:57 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=81=A2=E5=A4=8D=E8=AE=A4=E8=AF=81?= =?UTF-8?q?=E5=9B=BE=E6=A0=87=E6=82=AC=E6=B5=AE=E6=96=87=E6=A1=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/AKSRT/User/Home.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/AKSRT/User/Home.php b/src/AKSRT/User/Home.php index 64a42082..808d8810 100644 --- a/src/AKSRT/User/Home.php +++ b/src/AKSRT/User/Home.php @@ -143,7 +143,15 @@ class Home { $application = class_exists('AKSRT\\User\\AuthApply') ? AuthApply::get_apply_payload($user_id) : []; $type = sanitize_key((string) ($info['type'] ?? $application['type'] ?? '')); $type_settings = is_array($settings['verify']['types'][$type] ?? null) ? $settings['verify']['types'][$type] : []; - $label = (string) ($type_settings['badge_text'] ?? $type_settings['label'] ?? ''); + $label = trim((string) ($type_settings['badge_text'] ?? $type_settings['label'] ?? '')); + if ($label === '') { + foreach ((array) ($settings['verify']['types'] ?? []) as $configured_type) { + if (is_array($configured_type) && !empty($configured_type['badge_text'])) { + $label = trim((string) $configured_type['badge_text']); + break; + } + } + } $signals[] = [ 'type' => 'verify', 'label' => $label,