From ec3ec3b78a2a431b82ff16136dddd5e6900c3e1e Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Tue, 21 Jul 2020 21:39:59 -0400 Subject: [PATCH] Replace remaining occurrences of Network::curl --- src/Model/GContact.php | 3 ++- src/Model/GServer.php | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Model/GContact.php b/src/Model/GContact.php index ab0a4fdd8..41ca763fc 100644 --- a/src/Model/GContact.php +++ b/src/Model/GContact.php @@ -35,6 +35,7 @@ use Friendica\Network\Probe; use Friendica\Protocol\ActivityPub; use Friendica\Protocol\PortableContact; use Friendica\Util\DateTimeFormat; +use Friendica\Util\Network; use Friendica\Util\Strings; /** @@ -1377,7 +1378,7 @@ class GContact return; } - $curlResult = Network::curl($data['poco']); + $curlResult = DI::httpRequest()->get($data['poco']); if (!$curlResult->isSuccess()) { return; } diff --git a/src/Model/GServer.php b/src/Model/GServer.php index 7643c9590..0f47146eb 100644 --- a/src/Model/GServer.php +++ b/src/Model/GServer.php @@ -359,7 +359,7 @@ class GServer // When the base path doesn't seem to contain a social network we try the complete path. // Most detectable system have to be installed in the root directory. // We checked the base to avoid false positives. - $curlResult = Network::curl($url, false, ['timeout' => $xrd_timeout]); + $curlResult = DI::httpRequest()->get($url, false, ['timeout' => $xrd_timeout]); if ($curlResult->isSuccess()) { $urldata = self::analyseRootHeader($curlResult, $serverdata); $urldata = self::analyseRootBody($curlResult, $urldata, $url);