mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-11-29 21:01:03 +00:00
Adding skip_serializing_none to federation state. (#4152)
This commit is contained in:
parent
907e0ce726
commit
28c30cc502
2 changed files with 4 additions and 0 deletions
|
@ -328,6 +328,7 @@ pub struct FederatedInstances {
|
|||
pub blocked: Vec<InstanceWithFederationState>,
|
||||
}
|
||||
|
||||
#[skip_serializing_none]
|
||||
#[derive(Debug, Serialize, Deserialize, Clone)]
|
||||
#[cfg_attr(feature = "full", derive(TS))]
|
||||
#[cfg_attr(feature = "full", ts(export))]
|
||||
|
@ -350,6 +351,7 @@ impl From<FederationQueueState> for ReadableFederationState {
|
|||
}
|
||||
}
|
||||
|
||||
#[skip_serializing_none]
|
||||
#[derive(Debug, Serialize, Deserialize, Clone)]
|
||||
#[cfg_attr(feature = "full", derive(TS))]
|
||||
#[cfg_attr(feature = "full", ts(export))]
|
||||
|
|
|
@ -3,9 +3,11 @@ use chrono::{DateTime, Utc};
|
|||
#[cfg(feature = "full")]
|
||||
use diesel::prelude::*;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use serde_with::skip_serializing_none;
|
||||
#[cfg(feature = "full")]
|
||||
use ts_rs::TS;
|
||||
|
||||
#[skip_serializing_none]
|
||||
#[derive(Clone, Debug, Serialize, Deserialize)]
|
||||
#[cfg_attr(
|
||||
feature = "full",
|
||||
|
|
Loading…
Reference in a new issue