File tree Expand file tree Collapse file tree 3 files changed +7
-3
lines changed Expand file tree Collapse file tree 3 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -411,7 +411,6 @@ impl Manager {
411
411
. collect :: < Vec < _ > > ( )
412
412
. join ( "&" ) ;
413
413
414
-
415
414
// Url adds a trailing `/`
416
415
let url = format ! (
417
416
"{}units-for-slot/{}?pubPrefix={}&{}" ,
Original file line number Diff line number Diff line change @@ -135,6 +135,9 @@ pub struct ChannelListResponse {
135
135
#[ serde( rename_all = "camelCase" ) ]
136
136
pub struct LastApprovedResponse {
137
137
pub last_approved : Option < LastApproved > ,
138
+ /// None -> withHeartbeat=true wasn't passed
139
+ /// Some(vec![]) (empty vec) or Some(heartbeats) - withHeartbeats=true was passed
140
+ #[ serde( default , skip_serializing_if = "Option::is_none" ) ]
138
141
pub heartbeats : Option < Vec < HeartbeatValidatorMessage > > ,
139
142
}
140
143
Original file line number Diff line number Diff line change @@ -130,8 +130,10 @@ impl Into<SerdeValue> for Value {
130
130
Value :: Bool ( bool) => SerdeValue :: Bool ( bool) ,
131
131
Value :: Number ( number) => SerdeValue :: Number ( number) ,
132
132
Value :: String ( string) => SerdeValue :: String ( string) ,
133
- Value :: Array ( array) => SerdeValue :: Array ( array. into_iter ( ) . map ( |value| value. into ( ) ) . collect ( ) ) ,
134
- Value :: BigNum ( bignum) => SerdeValue :: String ( bignum. to_string ( ) )
133
+ Value :: Array ( array) => {
134
+ SerdeValue :: Array ( array. into_iter ( ) . map ( |value| value. into ( ) ) . collect ( ) )
135
+ }
136
+ Value :: BigNum ( bignum) => SerdeValue :: String ( bignum. to_string ( ) ) ,
135
137
}
136
138
}
137
139
}
You can’t perform that action at this time.
0 commit comments