Remove unwrap

This commit is contained in:
Felix Ableitner 2022-11-14 15:30:44 +01:00
parent a0fed24cee
commit 0b86ffbdbd

View file

@ -119,7 +119,10 @@ impl AnnounceActivity {
let announcable_page = RawAnnouncableActivities {
id: c.object.id.clone().into_inner(),
actor: c.actor.clone().into_inner(),
other: serde_json::to_value(c.object)?.as_object().unwrap().clone(),
other: serde_json::to_value(c.object)?
.as_object()
.expect("is object")
.clone(),
};
let announce_compat = AnnounceActivity::new(announcable_page, community, context)?;
send_lemmy_activity(context, announce_compat, community, inboxes, false).await?;