refactor:公共函数 full_url 默认域名不再携带协议,由浏览器自动识别或手动指定

This commit is contained in:
妙码生花 2024-03-09 15:56:15 +08:00
parent 902c2fab65
commit 2e1aedf57d

View File

@ -150,7 +150,7 @@ if (!function_exists('full_url')) {
Event::trigger('uploadConfigInit', App::getInstance());
$cdnUrl = Config::get('buildadmin.cdn_url');
if (!$cdnUrl) $cdnUrl = request()->upload['cdn'] ?? request()->domain();
if (!$cdnUrl) $cdnUrl = request()->upload['cdn'] ?? '//' . request()->host();
if ($domain === true) {
$domain = $cdnUrl;
} elseif ($domain === false) {