Make "HTTPRequest::curl" dynamic

This commit is contained in:
nupplaPhil 2020-03-04 22:15:46 +01:00 committed by Hypolite Petovan
parent 9d00e4f1bc
commit 2973ed6448
20 changed files with 72 additions and 84 deletions

View file

@ -28,7 +28,6 @@ use Friendica\Content\PageInfo;
use Friendica\Core\Hook;
use Friendica\Core\Logger;
use Friendica\Core\System;
use Friendica\Network\HTTPRequest;
use Friendica\Util\ParseUrl;
use Friendica\Util\Strings;
@ -85,7 +84,7 @@ function parse_url_content(App $a)
// Check if the URL is an image, video or audio file. If so format
// the URL with the corresponding BBCode media tag
// Fetch the header of the URL
$curlResponse = HTTPRequest::curl($url, false, ['novalidate' => true, 'nobody' => true]);
$curlResponse = DI::httpRequest()->curl($url, false, ['novalidate' => true, 'nobody' => true]);
if ($curlResponse->isSuccess()) {
// Convert the header fields into an array