From 71495ac61587e3380f413b4d34669a68b5cd8068 Mon Sep 17 00:00:00 2001 From: Julio Capote Date: Sun, 1 Jan 2023 10:10:09 -0500 Subject: add dates and stuff --- views/outbox.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'views/outbox.go') diff --git a/views/outbox.go b/views/outbox.go index 7ea4ace..bfe225a 100644 --- a/views/outbox.go +++ b/views/outbox.go @@ -36,14 +36,17 @@ func RenderOutboxCollection(name, domain string, page []models.OutboxItem) (map[ partOfProp := streams.NewActivityStreamsPartOfProperty() partOfProp.SetIRI(partOf) oc.SetActivityStreamsPartOf(partOfProp) - oc.SetActivityStreamsTo(toProp) itemsProp := streams.NewActivityStreamsOrderedItemsProperty() for _, v := range page { + publishedProp := streams.NewActivityStreamsPublishedProperty() + publishedProp.Set(v.CreatedAt) crea := streams.NewActivityStreamsCreate() obj := streams.NewActivityStreamsObjectProperty() crea.SetActivityStreamsObject(obj) + crea.SetActivityStreamsTo(toProp) + crea.SetActivityStreamsPublished(publishedProp) note := streams.NewActivityStreamsNote() contentProp := streams.NewActivityStreamsContentProperty() @@ -51,8 +54,7 @@ func RenderOutboxCollection(name, domain string, page []models.OutboxItem) (map[ note.SetActivityStreamsContent(contentProp) note.SetActivityStreamsTo(toProp) - // publishedProp := streams.NewActivityStreamsPublishedProperty() - // note.SetActivityStreamsPublished() + note.SetActivityStreamsPublished(publishedProp) obj.AppendActivityStreamsNote(note) itemsProp.AppendActivityStreamsCreate(crea) -- cgit v1.2.3