Make healthcheck a pointer to avoid empty json objects
@@ -28,12 +28,12 @@ type MagicTransitGRETunnel struct {
Description string `json:"description,omitempty"`
TTL uint8 `json:"ttl,omitempty"`
MTU uint16 `json:"mtu,omitempty"`
- HealthCheck MagicTransitGRETunnelHealthcheck `json:"health_check"`
+ HealthCheck *MagicTransitGRETunnelHealthcheck `json:"health_check,omitempty"`
}
// MagicTransitGRETunnelHealthcheck contains information about a GRE tunnel health check.
type MagicTransitGRETunnelHealthcheck struct {
- Enabled bool `json:"enabled,omitempty"`
+ Enabled bool `json:"enabled"`
Target string `json:"target,omitempty"`
Type string `json:"type,omitempty"`
}
