diff --git a/contracts/TornadoTrees.sol b/contracts/TornadoTrees.sol index b40fdd8..e0aab78 100644 --- a/contracts/TornadoTrees.sol +++ b/contracts/TornadoTrees.sol @@ -4,7 +4,7 @@ pragma solidity ^0.6.0; pragma experimental ABIEncoderV2; import "./interfaces/ITornadoTreesV1.sol"; -import "./interfaces/IVerifier.sol"; +import "./interfaces/IBatchTreeUpdateVerifier.sol"; contract TornadoTrees { address public immutable governance; @@ -13,7 +13,7 @@ contract TornadoTrees { bytes32 public withdrawalRoot; bytes32 public previousWithdrawalRoot; address public tornadoProxy; - IVerifier public treeUpdateVerifier; + IBatchTreeUpdateVerifier public treeUpdateVerifier; ITornadoTreesV1 public immutable tornadoTreesV1; // make sure CHUNK_TREE_HEIGHT has the same value in BatchTreeUpdate.circom @@ -70,7 +70,7 @@ contract TornadoTrees { address _governance, address _tornadoProxy, ITornadoTreesV1 _tornadoTreesV1, - IVerifier _treeUpdateVerifier, + IBatchTreeUpdateVerifier _treeUpdateVerifier, SearchParams memory _searchParams ) public { governance = _governance; @@ -271,7 +271,7 @@ contract TornadoTrees { tornadoProxy = _tornadoProxy; } - function setVerifierContract(IVerifier _treeUpdateVerifier) external onlyGovernance { + function setVerifierContract(IBatchTreeUpdateVerifier _treeUpdateVerifier) external onlyGovernance { treeUpdateVerifier = _treeUpdateVerifier; } diff --git a/contracts/interfaces/IVerifier.sol b/contracts/interfaces/IBatchTreeUpdateVerifier.sol similarity index 81% rename from contracts/interfaces/IVerifier.sol rename to contracts/interfaces/IBatchTreeUpdateVerifier.sol index 9a52a0f..c16aaa4 100644 --- a/contracts/interfaces/IVerifier.sol +++ b/contracts/interfaces/IBatchTreeUpdateVerifier.sol @@ -2,6 +2,6 @@ pragma solidity ^0.6.0; -interface IVerifier { +interface IBatchTreeUpdateVerifier { function verifyProof(bytes calldata proof, uint256[1] calldata input) external view returns (bool); } diff --git a/contracts/mocks/TornadoTreesMock.sol b/contracts/mocks/TornadoTreesMock.sol index d1e4bcd..1865b34 100644 --- a/contracts/mocks/TornadoTreesMock.sol +++ b/contracts/mocks/TornadoTreesMock.sol @@ -5,7 +5,7 @@ pragma experimental ABIEncoderV2; import "../TornadoTrees.sol"; import "../interfaces/ITornadoTreesV1.sol"; -import "../interfaces/IVerifier.sol"; +import "../interfaces/IBatchTreeUpdateVerifier.sol"; contract TornadoTreesMock is TornadoTrees { uint256 public currentBlock; @@ -14,7 +14,7 @@ contract TornadoTreesMock is TornadoTrees { address _governance, address _tornadoProxy, ITornadoTreesV1 _tornadoTreesV1, - IVerifier _treeUpdateVerifier, + IBatchTreeUpdateVerifier _treeUpdateVerifier, SearchParams memory _searchParams ) public TornadoTrees(_governance, _tornadoProxy, _tornadoTreesV1, _treeUpdateVerifier, _searchParams) {}