mirror of
https://github.com/friendica/friendica
synced 2025-04-26 13:50:11 +00:00
Rename DI::httpRequest() into DI::httpClient()
This commit is contained in:
parent
505100bdd7
commit
13a91e63aa
38 changed files with 94 additions and 94 deletions
|
@ -168,7 +168,7 @@ class Media
|
|||
// Fetch the mimetype or size if missing.
|
||||
if (empty($media['mimetype']) || empty($media['size'])) {
|
||||
$timeout = DI::config()->get('system', 'xrd_timeout');
|
||||
$curlResult = DI::httpRequest()->head($media['url'], [HTTPClientOptions::TIMEOUT => $timeout]);
|
||||
$curlResult = DI::httpClient()->head($media['url'], [HTTPClientOptions::TIMEOUT => $timeout]);
|
||||
if ($curlResult->isSuccess()) {
|
||||
if (empty($media['mimetype'])) {
|
||||
$media['mimetype'] = $curlResult->getHeader('Content-Type')[0] ?? '';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue