mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-04-23 23:16:53 +00:00
fix: wrong accept header in mastodonbridge (#3025)
Fixes bug introduced by afcc38786e
because of
the default Accept header which caused xml to be returned.
Fix #3024
This commit is contained in:
parent
94ae098ef5
commit
5a9336df12
@ -165,7 +165,7 @@ class MastodonBridge extends BridgeAbstract
|
|||||||
$resource = 'acct:' . $this->getUsername() . '@' . $this->getInstance();
|
$resource = 'acct:' . $this->getUsername() . '@' . $this->getInstance();
|
||||||
$webfingerUrl = 'https://' . $this->getInstance() . '/.well-known/webfinger?resource=' . $resource;
|
$webfingerUrl = 'https://' . $this->getInstance() . '/.well-known/webfinger?resource=' . $resource;
|
||||||
$webfingerHeader = [
|
$webfingerHeader = [
|
||||||
'Content-Type: application/jrd+json'
|
'Accept: application/jrd+json'
|
||||||
];
|
];
|
||||||
$webfinger = json_decode(getContents($webfingerUrl, $webfingerHeader), true);
|
$webfinger = json_decode(getContents($webfingerUrl, $webfingerHeader), true);
|
||||||
foreach ($webfinger['links'] as $link) {
|
foreach ($webfinger['links'] as $link) {
|
||||||
|
Loading…
Reference in New Issue
Block a user