From 81b6d3469388fbebcc9ccce36d43d2c1fc20b920 Mon Sep 17 00:00:00 2001 From: Sergio Chouhy Date: Thu, 10 Jul 2025 12:52:48 -0300 Subject: [PATCH] add Transaction::hash inline docs --- common/src/transaction.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/common/src/transaction.rs b/common/src/transaction.rs index e5056f5..cb86661 100644 --- a/common/src/transaction.rs +++ b/common/src/transaction.rs @@ -151,6 +151,7 @@ impl ActionData { } impl Transaction { + /// Computes and returns the SHA-256 hash of the JSON-serialized representation of `self`. pub fn hash(&self) -> TreeHashType { let raw_data = serde_json::to_vec(&self).unwrap(); let mut hasher = sha2::Sha256::new();