Skip to content

Commit

Permalink
quick clarification
Browse files Browse the repository at this point in the history
  • Loading branch information
Arvolear committed Nov 25, 2024
1 parent 52d88be commit 563a6c9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions ERCS/erc-7812.md
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,8 @@ The reference implementation of `EvidenceRegistry` and `EvidenceDB` Solidity sma

The low-level Solidity and Circom implementations of SMT can be found [here](../assets/eip-7812/contracts/SparseMerkleTree.sol) and [here](../assets/eip-7812/circuits/SparseMerkleTree.circom).

The height of the SMT is set to `80`.

> Please note that the reference implementation depends on the `@openzeppelin/contracts v5.1.0` and `circomlib v2.0.5`.
### EvidenceDB Implementation
Expand Down Expand Up @@ -318,7 +320,7 @@ contract EvidenceDB is IEvidenceDB, Initializable {
bytes32 element2_,
bytes32 element3_
) private pure returns (bytes32) {
return bytes32(PoseidonUnit3L.poseidon([element1_, element2_, element3_]));
return PoseidonUnit3L.poseidon([element1_, element2_, element3_]);
}
}
```
Expand Down Expand Up @@ -350,7 +352,7 @@ contract EvidenceRegistry is IEvidenceRegistry, Initializable {
}
modifier onRootUpdate() {
bytes32 prevRoot_ = _evidenceDB.getRoot();
bytes32 prevRoot_ = _evidenceDB.getRoot();
_rootTimestamps[prevRoot_] = block.timestamp;
_;
emit RootUpdated(prevRoot_, _evidenceDB.getRoot());
Expand Down

0 comments on commit 563a6c9

Please sign in to comment.