From 5a9336df12b1b7b3150e969be1767b69000be02e Mon Sep 17 00:00:00 2001 From: Dag Date: Sat, 10 Sep 2022 07:38:09 +0200 Subject: [PATCH] fix: wrong accept header in mastodonbridge (#3025) Fixes bug introduced by afcc38786e85cfe99efacfddb3a222989bd09f5e because of the default Accept header which caused xml to be returned. Fix #3024 --- bridges/MastodonBridge.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bridges/MastodonBridge.php b/bridges/MastodonBridge.php index ad87ba07..b0056bff 100644 --- a/bridges/MastodonBridge.php +++ b/bridges/MastodonBridge.php @@ -165,7 +165,7 @@ class MastodonBridge extends BridgeAbstract $resource = 'acct:' . $this->getUsername() . '@' . $this->getInstance(); $webfingerUrl = 'https://' . $this->getInstance() . '/.well-known/webfinger?resource=' . $resource; $webfingerHeader = [ - 'Content-Type: application/jrd+json' + 'Accept: application/jrd+json' ]; $webfinger = json_decode(getContents($webfingerUrl, $webfingerHeader), true); foreach ($webfinger['links'] as $link) {