From 313167905402f77959df6e7e20358bebf82a674f Mon Sep 17 00:00:00 2001 From: Dessalines Date: Thu, 6 Jan 2022 11:41:24 -0500 Subject: [PATCH] Removing ban_expires from federated fields. --- crates/apub/src/objects/person.rs | 3 +-- crates/apub/src/protocol/objects/person.rs | 1 - 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/crates/apub/src/objects/person.rs b/crates/apub/src/objects/person.rs index 8e3c7a34d..ff8f0a583 100644 --- a/crates/apub/src/objects/person.rs +++ b/crates/apub/src/objects/person.rs @@ -113,7 +113,6 @@ impl ApubObject for ApubPerson { updated: self.updated.map(convert_datetime), unparsed: Default::default(), inbox: self.inbox_url.clone().into(), - ban_expires: self.ban_expires.map(convert_datetime), }; Ok(person) } @@ -150,6 +149,7 @@ impl ApubObject for ApubPerson { name: person.preferred_username, display_name: Some(person.name), banned: None, + ban_expires: None, deleted: None, avatar: Some(person.icon.map(|i| i.url.into())), banner: Some(person.image.map(|i| i.url.into())), @@ -169,7 +169,6 @@ impl ApubObject for ApubPerson { inbox_url: Some(person.inbox.into()), shared_inbox_url: Some(person.endpoints.shared_inbox.map(|s| s.into())), matrix_user_id: Some(person.matrix_user_id), - ban_expires: Some(person.ban_expires.map(|u| u.naive_local())), }; let person = blocking(context.pool(), move |conn| { DbPerson::upsert(conn, &person_form) diff --git a/crates/apub/src/protocol/objects/person.rs b/crates/apub/src/protocol/objects/person.rs index c8d4dce26..f66b09aa0 100644 --- a/crates/apub/src/protocol/objects/person.rs +++ b/crates/apub/src/protocol/objects/person.rs @@ -39,7 +39,6 @@ pub struct Person { pub(crate) public_key: PublicKey, pub(crate) published: Option>, pub(crate) updated: Option>, - pub(crate) ban_expires: Option>, #[serde(flatten)] pub(crate) unparsed: Unparsed, }