mirror of
https://github.com/friendica/friendica
synced 2024-11-18 19:03:40 +00:00
Fix Notice: "Undefined index: host"
This commit is contained in:
parent
398e65d66b
commit
bdbe6771fd
1 changed files with 3 additions and 0 deletions
|
@ -1784,6 +1784,9 @@ class Probe
|
|||
$base = $xpath->evaluate('string(/html/head/base/@href)') ?: $base;
|
||||
|
||||
$baseParts = parse_url($base);
|
||||
if (empty($baseParts['host'])) {
|
||||
return $href;
|
||||
}
|
||||
|
||||
// Naked domain case (scheme://basehost)
|
||||
$path = $baseParts['path'] ?? '/';
|
||||
|
|
Loading…
Reference in a new issue