Skip to content

Commit

Permalink
fix: added skip_serialization for JSON fields (#632)
Browse files Browse the repository at this point in the history
Co-authored-by: Rob Ede <[email protected]>
  • Loading branch information
xtovski and robjtede authored Oct 29, 2023
1 parent 4bcc43f commit c15a176
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions json/jsonrpc/src/convention.rs
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ pub struct Response {
// This member is REQUIRED on error.
// This member MUST NOT exist if there was no error triggered during invocation.
// The value for this member MUST be an Object as defined in section 5.1.
#[serde(skip_serializing_if = "Option::is_none")]
pub error: Option<ErrorData>,

/// This member is REQUIRED.
Expand Down

0 comments on commit c15a176

Please sign in to comment.