From: Mikael Nordfeldth Date: Tue, 23 Feb 2016 22:50:57 +0000 (+0100) Subject: Properly attach activityobjects X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=9319033ff04427752b7b3758df50462cd926183b;p=quix0rs-gnu-social.git Properly attach activityobjects For some reason they were written to ->object, which is incorrect as we use the objects[] array (which usually just holds one entry though) --- diff --git a/plugins/OStatus/OStatusPlugin.php b/plugins/OStatus/OStatusPlugin.php index c108e78e6c..eaf09bf6fd 100644 --- a/plugins/OStatus/OStatusPlugin.php +++ b/plugins/OStatus/OStatusPlugin.php @@ -669,7 +669,7 @@ class OStatusPlugin extends Plugin $other->getBestName()); $act->actor = $profile->asActivityObject(); - $act->object = $other->asActivityObject(); + $act->objects[] = $other->asActivityObject(); $oprofile->notifyActivity($act, $profile); @@ -707,7 +707,7 @@ class OStatusPlugin extends Plugin $act->actor = $profile->asActivityObject(); $act->verb = ActivityVerb::JOIN; - $act->object = $oprofile->asActivityObject(); + $act->objects[] = $oprofile->asActivityObject(); $act->time = time(); // TRANS: Title for joining a remote groep. @@ -761,7 +761,7 @@ class OStatusPlugin extends Plugin $act->actor = $member->asActivityObject(); $act->verb = ActivityVerb::LEAVE; - $act->object = $oprofile->asActivityObject(); + $act->objects[] = $oprofile->asActivityObject(); $act->time = time(); // TRANS: Title for leaving a remote group. @@ -807,7 +807,7 @@ class OStatusPlugin extends Plugin $act->actor = $sub->asActivityObject(); $act->verb = ActivityVerb::FOLLOW; - $act->object = $oprofile->asActivityObject(); + $act->objects[] = $oprofile->asActivityObject(); $act->time = time(); // TRANS: Title for following a remote list. @@ -859,7 +859,7 @@ class OStatusPlugin extends Plugin $act->actor = $member->asActivityObject(); $act->verb = ActivityVerb::UNFOLLOW; - $act->object = $oprofile->asActivityObject(); + $act->objects[] = $oprofile->asActivityObject(); $act->time = time(); // TRANS: Title for unfollowing a remote list. @@ -1051,7 +1051,7 @@ class OStatusPlugin extends Plugin $notice->getUrl()); $act->actor = $profile->asActivityObject(); - $act->object = $notice->asActivityObject(); + $act->objects[] = $notice->asActivityObject(); $oprofile->notifyActivity($act, $profile); @@ -1173,7 +1173,7 @@ class OStatusPlugin extends Plugin $profile->getBestName()); $act->actor = $profile->asActivityObject(); - $act->object = $act->actor; + $act->objects[] = $act->actor; while ($oprofile->fetch()) { $oprofile->notifyDeferred($act, $profile);