From 855cd948ef2c212f77415d40a5ee84cddf5c2625 Mon Sep 17 00:00:00 2001 From: NicolasCantu Date: Fri, 7 Feb 2025 22:38:18 +0100 Subject: [PATCH] [bug] update_value also update the state_id --- src/process.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/process.rs b/src/process.rs index 474e9c6..ad553c5 100644 --- a/src/process.rs +++ b/src/process.rs @@ -83,6 +83,9 @@ impl ProcessState { // Todo for now we rehash everything, which is a bit wasteful but fine for a proto + // Update state_id + self.state_id = self.pcd_commitment.create_merkle_tree()?.root().unwrap().to_lower_hex_string(); + // Update the encrypted value Value::Object(clear_pcd).encrypt_fields(&[key.to_string()], &mut self.keys, self.encrypted_pcd.as_object_mut().unwrap())?;