Remove accept parameter for head/post again
This commit is contained in:
parent
4aeccd3157
commit
04866195b4
12 changed files with 54 additions and 57 deletions
|
@ -42,7 +42,6 @@ use Friendica\Model\Post;
|
|||
use Friendica\Model\Profile;
|
||||
use Friendica\Model\Tag;
|
||||
use Friendica\Model\User;
|
||||
use Friendica\Network\HTTPClient\Client\HttpClientAccept;
|
||||
use Friendica\Network\Probe;
|
||||
use Friendica\Util\Crypto;
|
||||
use Friendica\Util\DateTimeFormat;
|
||||
|
@ -1014,7 +1013,7 @@ class DFRN
|
|||
|
||||
$content_type = ($public_batch ? "application/magic-envelope+xml" : "application/json");
|
||||
|
||||
$postResult = DI::httpClient()->post($dest_url, $envelope, HttpClientAccept::DEFAULT, ['Content-Type' => $content_type]);
|
||||
$postResult = DI::httpClient()->post($dest_url, $envelope, ['Content-Type' => $content_type]);
|
||||
$xml = $postResult->getBody();
|
||||
|
||||
$curl_stat = $postResult->getReturnCode();
|
||||
|
|
|
@ -3018,7 +3018,7 @@ class Diaspora
|
|||
if (!intval(DI::config()->get("system", "diaspora_test"))) {
|
||||
$content_type = (($public_batch) ? "application/magic-envelope+xml" : "application/json");
|
||||
|
||||
$postResult = DI::httpClient()->post($dest_url . "/", $envelope, HttpClientAccept::DEFAULT, ['Content-Type' => $content_type]);
|
||||
$postResult = DI::httpClient()->post($dest_url . "/", $envelope, ['Content-Type' => $content_type]);
|
||||
$return_code = $postResult->getReturnCode();
|
||||
} else {
|
||||
Logger::notice("test_mode");
|
||||
|
|
|
@ -157,7 +157,7 @@ class Salmon
|
|||
$salmon = XML::fromArray($xmldata, $xml, false, $namespaces);
|
||||
|
||||
// slap them
|
||||
$postResult = DI::httpClient()->post($url, $salmon, HttpClientAccept::DEFAULT, [
|
||||
$postResult = DI::httpClient()->post($url, $salmon, [
|
||||
'Content-type' => 'application/magic-envelope+xml',
|
||||
'Content-length' => strlen($salmon),
|
||||
]);
|
||||
|
@ -182,7 +182,7 @@ class Salmon
|
|||
$salmon = XML::fromArray($xmldata, $xml, false, $namespaces);
|
||||
|
||||
// slap them
|
||||
$postResult = DI::httpClient()->post($url, $salmon, HttpClientAccept::DEFAULT, [
|
||||
$postResult = DI::httpClient()->post($url, $salmon, [
|
||||
'Content-type' => 'application/magic-envelope+xml',
|
||||
'Content-length' => strlen($salmon),
|
||||
]);
|
||||
|
@ -205,7 +205,7 @@ class Salmon
|
|||
$salmon = XML::fromArray($xmldata, $xml, false, $namespaces);
|
||||
|
||||
// slap them
|
||||
$postResult = DI::httpClient()->post($url, $salmon, HttpClientAccept::DEFAULT, [
|
||||
$postResult = DI::httpClient()->post($url, $salmon, [
|
||||
'Content-type' => 'application/magic-envelope+xml',
|
||||
'Content-length' => strlen($salmon)]);
|
||||
$return_code = $postResult->getReturnCode();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue