fix: ld_context to all

This commit is contained in:
əlemi 2024-03-21 19:32:07 +01:00
parent 017f508907
commit d318ccb782
Signed by: alemi
GPG key ID: A4895B84D311642C
2 changed files with 3 additions and 0 deletions

View file

@ -47,6 +47,7 @@ pub async fn view(State(ctx): State<Context>) -> Result<Json<serde_json::Value>,
.set_summary(Some("micro social network, federated")) .set_summary(Some("micro social network, federated"))
.set_inbox(Node::link(url!(ctx, "/inbox"))) .set_inbox(Node::link(url!(ctx, "/inbox")))
.set_outbox(Node::link(url!(ctx, "/outbox"))) .set_outbox(Node::link(url!(ctx, "/outbox")))
.ld_context()
)) ))
} }

View file

@ -64,6 +64,7 @@ pub async fn outbox(
.set_part_of(Node::link(url!(ctx, "/users/{id}/outbox"))) .set_part_of(Node::link(url!(ctx, "/users/{id}/outbox")))
.set_next(Node::link(url!(ctx, "/users/{id}/outbox?page=true&max_id={next}"))) .set_next(Node::link(url!(ctx, "/users/{id}/outbox?page=true&max_id={next}")))
.set_ordered_items(Node::array(items)) .set_ordered_items(Node::array(items))
.ld_context()
)) ))
}, },
} }
@ -74,6 +75,7 @@ pub async fn outbox(
.set_id(Some(&url!(ctx, "/users/{id}/outbox"))) .set_id(Some(&url!(ctx, "/users/{id}/outbox")))
.set_collection_type(Some(CollectionType::OrderedCollection)) .set_collection_type(Some(CollectionType::OrderedCollection))
.set_first(Node::link(url!(ctx, "/users/{id}/outbox?page=true"))) .set_first(Node::link(url!(ctx, "/users/{id}/outbox?page=true")))
.ld_context()
)) ))
} }
} }