From b1e4c4e79b6f8b6cd329c3e13f1118ba538f8cc5 Mon Sep 17 00:00:00 2001 From: alemi Date: Wed, 1 May 2024 21:21:26 +0200 Subject: [PATCH] fix: add sensitive to context since we use it --- src/routes/activitypub/jsonld.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/routes/activitypub/jsonld.rs b/src/routes/activitypub/jsonld.rs index e351349c..d0f0d300 100644 --- a/src/routes/activitypub/jsonld.rs +++ b/src/routes/activitypub/jsonld.rs @@ -15,10 +15,13 @@ pub trait LD { impl LD for serde_json::Value { fn ld_context(mut self) -> Self { if let Some(obj) = self.as_object_mut() { + let mut ctx = serde_json::Map::new(); + ctx.insert("sensitive".to_string(), serde_json::Value::String("as:sensitive".into())); obj.insert( "@context".to_string(), serde_json::Value::Array(vec![ - serde_json::Value::String("https://www.w3.org/ns/activitystreams".into()) + serde_json::Value::String("https://www.w3.org/ns/activitystreams".into()), + serde_json::Value::Object(ctx), ]), ); } else {