From 1df965ee5a13921f30a453cd81be6def8f19c2b3 Mon Sep 17 00:00:00 2001 From: FChannel <> Date: Mon, 4 Oct 2021 19:47:46 -0700 Subject: fix for faking post IDs --- outboxPost.go | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'outboxPost.go') diff --git a/outboxPost.go b/outboxPost.go index cb48d3e..65b9929 100644 --- a/outboxPost.go +++ b/outboxPost.go @@ -537,14 +537,23 @@ func ParseInboxRequest(w http.ResponseWriter, r *http.Request, db *sql.DB) { switch activity.Type { case "Create": + for _, e := range activity.To { if IsActorLocal(db, e) { if !IsActorLocal(db, activity.Actor.Id) { + + col := GetCollectionFromID(activity.Object.Id) + + if len(col.OrderedItems) < 1 { + break + } + WriteObjectToCache(db, *activity.Object) ArchivePosts(db, GetActorFromDB(db, e)) } } } + break case "Delete": -- cgit v1.2.3