diff --git a/solidity/scripts/tokens/Zeto_Anon.ts b/solidity/scripts/tokens/Zeto_Anon.ts index 6d0d01c..7320553 100644 --- a/solidity/scripts/tokens/Zeto_Anon.ts +++ b/solidity/scripts/tokens/Zeto_Anon.ts @@ -25,9 +25,9 @@ export async function deployDependencies() { deployer, args: [ await deployer.getAddress(), + verifier.target, depositVerifier.target, - withdrawVerifier.target, - verifier.target + withdrawVerifier.target ] }; } \ No newline at end of file diff --git a/solidity/scripts/tokens/Zeto_AnonEnc.ts b/solidity/scripts/tokens/Zeto_AnonEnc.ts index dedf480..929a61b 100644 --- a/solidity/scripts/tokens/Zeto_AnonEnc.ts +++ b/solidity/scripts/tokens/Zeto_AnonEnc.ts @@ -25,9 +25,9 @@ export async function deployDependencies() { deployer, args: [ await deployer.getAddress(), + verifier.target, depositVerifier.target, - withdrawVerifier.target, - verifier.target + withdrawVerifier.target ] }; } \ No newline at end of file diff --git a/solidity/scripts/tokens/Zeto_AnonEncNullifier.ts b/solidity/scripts/tokens/Zeto_AnonEncNullifier.ts index 2d79ab1..8ea1f6e 100644 --- a/solidity/scripts/tokens/Zeto_AnonEncNullifier.ts +++ b/solidity/scripts/tokens/Zeto_AnonEncNullifier.ts @@ -25,9 +25,9 @@ export async function deployDependencies() { deployer, args: [ await deployer.getAddress(), + verifier.target, depositVerifier.target, - withdrawVerifier.target, - verifier.target + withdrawVerifier.target ], libraries: { SmtLib: smtLib.target, diff --git a/solidity/scripts/tokens/Zeto_AnonEncNullifierNonRepudiation.ts b/solidity/scripts/tokens/Zeto_AnonEncNullifierNonRepudiation.ts index 9f4b036..d07be02 100644 --- a/solidity/scripts/tokens/Zeto_AnonEncNullifierNonRepudiation.ts +++ b/solidity/scripts/tokens/Zeto_AnonEncNullifierNonRepudiation.ts @@ -25,9 +25,9 @@ export async function deployDependencies() { deployer, args: [ await deployer.getAddress(), + verifier.target, depositVerifier.target, - withdrawVerifier.target, - verifier.target + withdrawVerifier.target ], libraries: { SmtLib: smtLib.target, diff --git a/solidity/scripts/tokens/Zeto_AnonNullifier.ts b/solidity/scripts/tokens/Zeto_AnonNullifier.ts index 7704561..2535f84 100644 --- a/solidity/scripts/tokens/Zeto_AnonNullifier.ts +++ b/solidity/scripts/tokens/Zeto_AnonNullifier.ts @@ -25,9 +25,9 @@ export async function deployDependencies() { deployer, args: [ await deployer.getAddress(), + verifier.target, depositVerifier.target, - withdrawVerifier.target, - verifier.target + withdrawVerifier.target ], libraries: { SmtLib: smtLib.target, diff --git a/solidity/scripts/tokens/Zeto_AnonNullifierKyc.ts b/solidity/scripts/tokens/Zeto_AnonNullifierKyc.ts index 098ba21..6b7e06b 100644 --- a/solidity/scripts/tokens/Zeto_AnonNullifierKyc.ts +++ b/solidity/scripts/tokens/Zeto_AnonNullifierKyc.ts @@ -25,9 +25,9 @@ export async function deployDependencies() { deployer, args: [ await deployer.getAddress(), + verifier.target, depositVerifier.target, - withdrawVerifier.target, - verifier.target + withdrawVerifier.target ], libraries: { SmtLib: smtLib.target, diff --git a/solidity/test/lib/deploy.ts b/solidity/test/lib/deploy.ts index d0e078e..b35006c 100644 --- a/solidity/test/lib/deploy.ts +++ b/solidity/test/lib/deploy.ts @@ -36,19 +36,21 @@ export async function deployZeto(tokenName: string) { const deployFunc = isFungible ? deployFungibleCloneable : deployNonFungibleCloneable; const result = await deployFunc(tokenName); ({ deployer, zetoImpl, erc20, args } = result as any); - const [deployerAddr, depositVerifier, withdrawVerifier, verifier] = args; + const [deployerAddr, verifier, depositVerifier, withdrawVerifier] = args; // we want to test the effectiveness of the factory contract // to create clones of the Zeto implementation contract const Factory = await ethers.getContractFactory("ZetoTokenFactory"); const factory = await Factory.deploy(); await factory.waitForDeployment(); - const tx1 = await factory.connect(deployer).registerImplementation(tokenName, { + + const implInfo = { implementation: zetoImpl.target, - depositVerifier, - withdrawVerifier, + depositVerifier: depositVerifier || verifier, + withdrawVerifier: withdrawVerifier || verifier, verifier - } as any); + }; + const tx1 = await factory.connect(deployer).registerImplementation(tokenName, implInfo as any); await tx1.wait(); let tx2; if (isFungible) {