Changes:
- added more missing type-hints (checked them in body of the method) - reformatted code a little (code-style) - moved '/.well-known/host-meta' to constant Probe::HOST_META
This commit is contained in:
@@ -1325,7 +1325,7 @@ class GServer
|
||||
private static function validHostMeta(string $url): bool
|
||||
{
|
||||
$xrd_timeout = DI::config()->get('system', 'xrd_timeout');
|
||||
$curlResult = DI::httpClient()->get($url . '/.well-known/host-meta', HttpClientAccept::XRD_XML, [HttpClientOptions::TIMEOUT => $xrd_timeout]);
|
||||
$curlResult = DI::httpClient()->get($url . Probe::HOST_META, HttpClientAccept::XRD_XML, [HttpClientOptions::TIMEOUT => $xrd_timeout]);
|
||||
if (!$curlResult->isSuccess()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user