diff --git a/app/utils/CheckUtils.php b/app/utils/CheckUtils.php index 523b378..fea5529 100644 --- a/app/utils/CheckUtils.php +++ b/app/utils/CheckUtils.php @@ -12,12 +12,12 @@ class CheckUtils if (!$urlarr) { return ['status' => false, 'errmsg' => 'Invalid URL', 'usetime' => 0]; } - if (str_starts_with($urlarr['host'], '[') && str_ends_with($urlarr['host'], ']')) { - $urlarr['host'] = substr($urlarr['host'], 1, -1); - } + if (str_starts_with($urlarr['host'], '[') && str_ends_with($urlarr['host'], ']')) { + $urlarr['host'] = substr($urlarr['host'], 1, -1); + } if (!empty($ip) && !filter_var($urlarr['host'], FILTER_VALIDATE_IP) && filter_var($ip, FILTER_VALIDATE_IP)) { - $port = $urlarr['port'] ?? ($urlarr['scheme'] == 'https' ? 443 : 80); - $resolve = $urlarr['host'] . ':' . $port . ':' . $ip; + $port = $urlarr['port'] ?? ($urlarr['scheme'] == 'https' ? 443 : 80); + $resolve = $urlarr['host'] . ':' . $port . ':' . $ip; } $ch = curl_init(); if ($proxy) { diff --git a/app/view/index/index.html b/app/view/index/index.html index 5b9d0a1..4621bb8 100644 --- a/app/view/index/index.html +++ b/app/view/index/index.html @@ -71,25 +71,25 @@
| 框架版本 | {$info.framework_version} | -||
| PHP版本 | {$info.php_version} | @@ -157,10 +157,10 @@数据库版本 | {$info.mysql_version} |
| Web服务器 | {$info.software} | -||
| 服务器时间 | {$info.date} |