From f680cb1fad8c1b43e4edfb134a5f477735303283 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Sat, 9 Mar 2019 02:15:16 -0700 Subject: [PATCH] Update AP inbox --- app/Util/ActivityPub/Inbox.php | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/app/Util/ActivityPub/Inbox.php b/app/Util/ActivityPub/Inbox.php index af5270ee..cfb1bd62 100644 --- a/app/Util/ActivityPub/Inbox.php +++ b/app/Util/ActivityPub/Inbox.php @@ -197,19 +197,15 @@ class Inbox 'item_type' => 'App\Profile' ]); } - + $payload = $this->payload; + $payload = unset($payload['@context']); // send Accept to remote profile $accept = [ '@context' => 'https://www.w3.org/ns/activitystreams', 'id' => $target->permalink().'#accepts/follows/' . $follower->id, 'type' => 'Accept', 'actor' => $target->permalink(), - 'object' => [ - 'id' => $this->payload['id'], - 'type' => 'Follow', - 'actor' => $actor->permalink(), - 'object' => $target->permalink() - ] + 'object' => $payload ]; Helpers::sendSignedObject($target, $actor->inbox_url, $accept); }