From 216855d3a7edcb1cc69f5894ddac9fdc9aca995e Mon Sep 17 00:00:00 2001 From: Kitaiti Makoto Date: Mon, 7 Mar 2022 00:15:19 +0900 Subject: [PATCH] Add SourceProperty to LicensedArticle --- plume-common/src/activity_pub/mod.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/plume-common/src/activity_pub/mod.rs b/plume-common/src/activity_pub/mod.rs index 40cbe05b..622c5508 100644 --- a/plume-common/src/activity_pub/mod.rs +++ b/plume-common/src/activity_pub/mod.rs @@ -573,7 +573,7 @@ where } } -pub type LicensedArticle = Ext1, Licensed07>; +pub type LicensedArticle = Ext2, Licensed07, SourceProperty>; pub trait ToAsString { fn to_as_string(&self) -> Option; @@ -689,6 +689,12 @@ mod tests { Licensed07 { license: "CC-0".into(), }, + SourceProperty { + source: Source { + content: "content".into(), + media_type: "text/plain".into(), + }, + }, ); let expected = json!({ "type": "Article",