mirror of
https://github.com/friendica/friendica
synced 2024-11-18 07:03:40 +00:00
Merge pull request #12483 from annando/issue-12419
Issue 12419: Quickhack to make GoToSocial work
This commit is contained in:
commit
0d4ea4b7f0
1 changed files with 6 additions and 0 deletions
|
@ -177,6 +177,12 @@ class JsonLD
|
|||
if (!in_array('https://w3id.org/security/v1', $json['@context'])) {
|
||||
$json['@context'][] = 'https://w3id.org/security/v1';
|
||||
}
|
||||
|
||||
// Issue 12419: Workaround for GoToSocial
|
||||
$pos = array_search('http://joinmastodon.org/ns', $json['@context']);
|
||||
if (is_int($pos)) {
|
||||
$json['@context'][$pos] = ['toot' => 'http://joinmastodon.org/ns#'];
|
||||
}
|
||||
}
|
||||
|
||||
// Bookwyrm transmits "id" fields with "null", which isn't allowed.
|
||||
|
|
Loading…
Reference in a new issue