Skip to content

Commit

Permalink
additional check
Browse files Browse the repository at this point in the history
  • Loading branch information
stojanov-igor committed Jul 1, 2024
1 parent d08d063 commit b09f82a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions jam/src/blockchain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ impl Blockchain {
if current_block.previous_hash != previous_block.block_hash {
return false;
}
if current_block.state_root != calculate_state_root(current_block.transactions.clone()) {
return false;
}
}
true
}
Expand Down

0 comments on commit b09f82a

Please sign in to comment.