From 675d8fad461e3b7e22d4c9e2d3d14ae3170ad0cb Mon Sep 17 00:00:00 2001 From: Felix Ableitner Date: Wed, 20 Nov 2024 12:42:59 +0100 Subject: [PATCH] fix ts --- crates/api_common/src/site.rs | 2 ++ crates/db_schema/src/source/federation_blocklist.rs | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/crates/api_common/src/site.rs b/crates/api_common/src/site.rs index db32f9edd..5d4220865 100644 --- a/crates/api_common/src/site.rs +++ b/crates/api_common/src/site.rs @@ -669,7 +669,9 @@ pub struct BlockInstanceResponse { pub struct AdminBlockInstanceParams { pub instance_id: InstanceId, pub block: bool, + #[cfg_attr(feature = "full", ts(optional))] pub reason: Option, + #[cfg_attr(feature = "full", ts(optional))] pub expires: Option>, } diff --git a/crates/db_schema/src/source/federation_blocklist.rs b/crates/db_schema/src/source/federation_blocklist.rs index 2f8021d9d..18eb9e060 100644 --- a/crates/db_schema/src/source/federation_blocklist.rs +++ b/crates/db_schema/src/source/federation_blocklist.rs @@ -24,7 +24,9 @@ use { pub struct FederationBlockList { pub instance_id: InstanceId, pub published: DateTime, + #[cfg_attr(feature = "full", ts(optional))] pub updated: Option>, + #[cfg_attr(feature = "full", ts(optional))] pub block_expires: Option>, } @@ -54,7 +56,9 @@ pub struct AdminBlockInstance { pub id: i32, pub instance_id: InstanceId, pub admin_person_id: PersonId, + #[cfg_attr(feature = "full", ts(optional))] pub reason: Option, + #[cfg_attr(feature = "full", ts(optional))] pub expires: Option>, pub published: DateTime, }