Skip to content

Commit

Permalink
Add support for serializing serde_json::Value::Null (fixes nox#110)
Browse files Browse the repository at this point in the history
  • Loading branch information
pymongo committed Nov 18, 2023
1 parent d8bc15d commit bc9ef12
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ser/part.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ impl<S: Sink> ser::Serializer for PartSerializer<S> {
}

fn serialize_unit(self) -> Result<S::Ok, Error> {
Err(self.sink.unsupported())
self.sink.serialize_none()
}

fn serialize_unit_struct(self, name: &'static str) -> Result<S::Ok, Error> {
Expand Down

0 comments on commit bc9ef12

Please sign in to comment.