mirror of
https://github.com/friendica/friendica
synced 2025-04-27 08:30:10 +00:00
Request type set for all HTTP requests
This commit is contained in:
parent
d788cb82cc
commit
5751e024c0
30 changed files with 129 additions and 90 deletions
|
@ -29,6 +29,7 @@ use Friendica\Model\Profile;
|
|||
use Friendica\Model\User;
|
||||
use Friendica\Network\HTTPClient\Client\HttpClientAccept;
|
||||
use Friendica\Network\HTTPClient\Client\HttpClientOptions;
|
||||
use Friendica\Network\HTTPClient\Client\HttpClientRequest;
|
||||
use GuzzleHttp\Psr7\Uri;
|
||||
|
||||
/* This class is used to verify the homepage link of a user profile.
|
||||
|
@ -64,7 +65,7 @@ class CheckRelMeProfileLink
|
|||
}
|
||||
|
||||
$xrd_timeout = DI::config()->get('system', 'xrd_timeout');
|
||||
$curlResult = DI::httpClient()->get($owner['homepage'], HttpClientAccept::HTML, [HttpClientOptions::TIMEOUT => $xrd_timeout]);
|
||||
$curlResult = DI::httpClient()->get($owner['homepage'], HttpClientAccept::HTML, [HttpClientOptions::TIMEOUT => $xrd_timeout, HttpClientOptions::REQUEST => HttpClientRequest::CONTACTVERIFIER]);
|
||||
if (!$curlResult->isSuccess()) {
|
||||
Logger::notice('Could not cURL the homepage URL', ['owner homepage' => $owner['homepage']]);
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue