Skip to content

Commit

Permalink
fix(lua): dont serialize hash when None
Browse files Browse the repository at this point in the history
because it becomes an `userdata: NULL` and not `nil`, what??
  • Loading branch information
alemidev committed Nov 17, 2024
1 parent ec6e131 commit 0c8c4a6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/api/change.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#[cfg_attr(feature = "serialize", derive(serde::Serialize, serde::Deserialize))]
pub struct BufferUpdate {
/// Optional content hash after applying this change.
#[cfg_attr(feature = "serialize", serde(skip_serializing_if = "Option::is_none"))]
pub hash: Option<i64>,
/// CRDT version after this change has been applied.
pub version: Vec<i64>,
Expand Down

0 comments on commit 0c8c4a6

Please sign in to comment.