mirror of
https://github.com/friendica/friendica
synced 2025-04-24 13:10:11 +00:00
Make "HTTPRequest::curl" dynamic
This commit is contained in:
parent
9d00e4f1bc
commit
2973ed6448
20 changed files with 72 additions and 84 deletions
|
@ -32,7 +32,6 @@ use Friendica\DI;
|
|||
use Friendica\Model\Register;
|
||||
use Friendica\Module\BaseAdmin;
|
||||
use Friendica\Network\HTTPException\InternalServerErrorException;
|
||||
use Friendica\Network\HTTPRequest;
|
||||
use Friendica\Util\ConfigFileLoader;
|
||||
use Friendica\Util\DateTimeFormat;
|
||||
|
||||
|
@ -247,7 +246,7 @@ class Summary extends BaseAdmin
|
|||
private static function checkSelfHostMeta()
|
||||
{
|
||||
// Fetch the host-meta to check if this really is a vital server
|
||||
return HTTPRequest::curl(DI::baseUrl()->get() . '/.well-known/host-meta')->isSuccess();
|
||||
return DI::httpRequest()->curl(DI::baseUrl()->get() . '/.well-known/host-meta')->isSuccess();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -27,7 +27,6 @@ use Friendica\Core\System;
|
|||
use Friendica\Database\DBA;
|
||||
use Friendica\DI;
|
||||
use Friendica\Model\Contact;
|
||||
use Friendica\Network\HTTPRequest;
|
||||
use Friendica\Util\HTTPSignature;
|
||||
use Friendica\Util\Strings;
|
||||
|
||||
|
@ -101,7 +100,7 @@ class Magic extends BaseModule
|
|||
);
|
||||
|
||||
// Try to get an authentication token from the other instance.
|
||||
$curlResult = HTTPRequest::curl($basepath . '/owa', false, ['headers' => $headers]);
|
||||
$curlResult = DI::httpRequest()->curl($basepath . '/owa', false, ['headers' => $headers]);
|
||||
|
||||
if ($curlResult->isSuccess()) {
|
||||
$j = json_decode($curlResult->getBody(), true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue