mirror of
https://github.com/tornadocash/tornado-core.git
synced 2024-11-26 11:48:57 +01:00
add timestamp
This commit is contained in:
parent
13b9a948dc
commit
93efd2548b
@ -13,7 +13,7 @@ contract Mixer is MerkleTreeWithHistory {
|
|||||||
mapping(uint256 => bool) public commitments;
|
mapping(uint256 => bool) public commitments;
|
||||||
IVerifier verifier;
|
IVerifier verifier;
|
||||||
|
|
||||||
event Deposit(uint256 indexed commitment, uint256 leafIndex);
|
event Deposit(uint256 indexed commitment, uint256 leafIndex, uint256 timestamp);
|
||||||
event Withdraw(address to, uint256 nullifier, uint256 fee);
|
event Withdraw(address to, uint256 nullifier, uint256 fee);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -40,7 +40,7 @@ contract Mixer is MerkleTreeWithHistory {
|
|||||||
require(!commitments[commitment], "The commitment has been submitted");
|
require(!commitments[commitment], "The commitment has been submitted");
|
||||||
_insert(commitment);
|
_insert(commitment);
|
||||||
commitments[commitment] = true;
|
commitments[commitment] = true;
|
||||||
emit Deposit(commitment, next_index - 1);
|
emit Deposit(commitment, next_index - 1, block.timestamp);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user