1
0
Fork 0
forked from alemi/upub

fix: fill addressing for outbound note activities

This commit is contained in:
əlemi 2024-06-08 15:55:07 +02:00
parent a8257deeeb
commit f664cb1cbe
Signed by: alemi
GPG key ID: A4895B84D311642C
2 changed files with 5 additions and 1 deletions

View file

@ -1,5 +1,5 @@
use apb::{ActivityMut, ObjectMut}; use apb::{ActivityMut, ObjectMut};
use sea_orm::{sea_query::{IntoColumnRef, IntoCondition}, ColumnTrait, Condition, ConnectionTrait, DbErr, EntityName, EntityTrait, FromQueryResult, Iden, Iterable, LoaderTrait, ModelTrait, Order, QueryFilter, QueryOrder, QueryResult, QuerySelect, RelationTrait, Select, SelectColumns}; use sea_orm::{sea_query::IntoCondition, ColumnTrait, Condition, ConnectionTrait, DbErr, EntityName, EntityTrait, FromQueryResult, Iden, Iterable, LoaderTrait, ModelTrait, Order, QueryFilter, QueryOrder, QueryResult, QuerySelect, RelationTrait, Select, SelectColumns};
use crate::model; use crate::model;

View file

@ -12,6 +12,10 @@ pub async fn process(ctx: Context, job: &model::job::Model) -> crate::JobResult<
if matches!(t, apb::ObjectType::Note) { if matches!(t, apb::ObjectType::Note) {
activity = apb::new() activity = apb::new()
.set_activity_type(Some(apb::ActivityType::Create)) .set_activity_type(Some(apb::ActivityType::Create))
.set_to(activity.to())
.set_bto(activity.bto())
.set_cc(activity.cc())
.set_bcc(activity.bcc())
.set_object(apb::Node::object(activity)); .set_object(apb::Node::object(activity));
t = apb::ObjectType::Activity(apb::ActivityType::Create); t = apb::ObjectType::Activity(apb::ActivityType::Create);
} }