From 9319c762a5431259359a830da6f1ca9f0850041a Mon Sep 17 00:00:00 2001 From: Dessalines Date: Sun, 4 Feb 2024 21:48:01 -0500 Subject: [PATCH] Fixing ts-rs serialization. --- crates/api_common/src/post.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/crates/api_common/src/post.rs b/crates/api_common/src/post.rs index f7be33a8e..ecad658b0 100644 --- a/crates/api_common/src/post.rs +++ b/crates/api_common/src/post.rs @@ -28,6 +28,7 @@ pub struct CreatePost { pub honeypot: Option, pub nsfw: Option, pub language_id: Option, + #[cfg_attr(feature = "full", ts(type = "string"))] /// Instead of fetching a thumbnail, use a custom one. pub custom_thumbnail: Option, } @@ -116,6 +117,7 @@ pub struct EditPost { pub body: Option, pub nsfw: Option, pub language_id: Option, + #[cfg_attr(feature = "full", ts(type = "string"))] /// Instead of fetching a thumbnail, use a custom one. pub custom_thumbnail: Option, }