Make Move activity federate properly

Ref: emit-move
This commit is contained in:
Tusooa Zhu 2021-09-12 16:45:17 -04:00
parent 1d8abf2511
commit e41eee5ed1
No known key found for this signature in database
GPG Key ID: 7B467EDE43A08224
2 changed files with 6 additions and 2 deletions

View File

@ -413,7 +413,8 @@ defmodule Pleroma.Web.ActivityPub.ActivityPub do
"type" => "Move", "type" => "Move",
"actor" => origin.ap_id, "actor" => origin.ap_id,
"object" => origin.ap_id, "object" => origin.ap_id,
"target" => target.ap_id "target" => target.ap_id,
"to" => [origin.follower_address]
} }
with true <- origin.ap_id in target.also_known_as, with true <- origin.ap_id in target.also_known_as,

View File

@ -1739,9 +1739,12 @@ defmodule Pleroma.Web.ActivityPub.ActivityPubTest do
"target" => ^new_ap_id, "target" => ^new_ap_id,
"type" => "Move" "type" => "Move"
}, },
local: true local: true,
recipients: recipients
} = activity } = activity
assert old_user.follower_address in recipients
params = %{ params = %{
"op" => "move_following", "op" => "move_following",
"origin_id" => old_user.id, "origin_id" => old_user.id,