Merge pull request #6427 from grahhnt/fix-jsonld-array-accessors

Allow Create activites' 'to' and 'cc' properties to be JSON-LD compliant
pull/6441/head
dansup 3 weeks ago committed by GitHub
commit 347ffd89a1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -252,6 +252,10 @@ class Inbox
$to = isset($activity['to']) ? $activity['to'] : [];
$cc = isset($activity['cc']) ? $activity['cc'] : [];
// JSON-LD allows for arrays with one element to be represented with just the value alone
if (is_string($to)) $to = [$to];
if (is_string($cc)) $cc = [$cc];
if ($activity['type'] == 'Question') {
// $this->handlePollCreate();

Loading…
Cancel
Save