head fixings

This commit is contained in:
Philipp 2022-04-08 20:41:25 +02:00
parent 277cd51433
commit 8e2cc678dc
No known key found for this signature in database
GPG key ID: 24A7501396EB5432
2 changed files with 4 additions and 2 deletions

View file

@ -101,7 +101,7 @@ class Link
{
$timeout = DI::config()->get('system', 'xrd_timeout');
$curlResult = DI::httpClient()->head($url, $accept, [HttpClientOptions::TIMEOUT => $timeout]);
$curlResult = DI::httpClient()->head($url, [HttpClientOptions::TIMEOUT => $timeout, HttpClientOptions::ACCEPT_CONTENT => $accept]);
if ($curlResult->isSuccess()) {
if (empty($media['mimetype'])) {
return $curlResult->getHeader('Content-Type')[0] ?? '';