mirror of
https://github.com/deuxfleurs-org/garage.git
synced 2026-08-21 02:16:37 +00:00
fix: mark to skip serialization of Option when None
mark with `skip_serializing_if = "Option::is_none"`
This commit is contained in:
+2
-2
@@ -94,9 +94,9 @@ pub struct CorsConfiguration {
|
||||
|
||||
#[derive(Debug, Serialize, Deserialize, PartialEq, Eq, PartialOrd, Ord)]
|
||||
pub struct CorsRule {
|
||||
#[serde(rename = "ID")]
|
||||
#[serde(rename = "ID", skip_serializing_if = "Option::is_none")]
|
||||
pub id: Option<Value>,
|
||||
#[serde(rename = "MaxAgeSeconds")]
|
||||
#[serde(rename = "MaxAgeSeconds", skip_serializing_if = "Option::is_none")]
|
||||
pub max_age_seconds: Option<IntValue>,
|
||||
#[serde(rename = "AllowedOrigin")]
|
||||
pub allowed_origins: Vec<Value>,
|
||||
|
||||
Reference in New Issue
Block a user