diff --git a/rust/altrios-core/src/track/link/link_impl.rs b/rust/altrios-core/src/track/link/link_impl.rs index 9ffed982..11a2f75f 100644 --- a/rust/altrios-core/src/track/link/link_impl.rs +++ b/rust/altrios-core/src/track/link/link_impl.rs @@ -39,7 +39,7 @@ pub struct Link { /// Spatial vector of compass heading values and corresponding positions along track pub headings: Vec, /// Map of train types and corresponding speed sets - #[serde(default)] + #[serde(default, skip_serializing_if = "HashMap::is_empty")] pub speed_sets: HashMap, /// Optional train-type-neutral [SpeedSet]. If provided, overrides [Link::speed_sets]. pub speed_set: Option,