From 81d60656e686f7d0f2ea890687590911b76531fa Mon Sep 17 00:00:00 2001 From: silverpill Date: Tue, 4 Jan 2022 21:54:41 +0000 Subject: [PATCH] Set correct primary audience for Update(Person) activities --- src/activitypub/activity.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/activitypub/activity.rs b/src/activitypub/activity.rs index ffef896..1d2f295 100644 --- a/src/activitypub/activity.rs +++ b/src/activitypub/activity.rs @@ -460,7 +460,10 @@ pub fn create_activity_update_person( UPDATE, None, actor, - vec![AP_PUBLIC.to_string()], + vec![ + AP_PUBLIC.to_string(), + get_followers_url(instance_url, &user.profile.username), + ], vec![], ); Ok(activity) @@ -588,5 +591,6 @@ mod tests { assert_eq!(activity.object["object"], Value::Null); assert_eq!(activity.object["content"], Value::Null); assert_eq!(activity.to.unwrap(), json!([target_actor_id])); + assert_eq!(activity.cc.unwrap(), json!([])); } }