can specify different account

This commit is contained in:
Moon Man 2023-01-30 14:32:53 -05:00
parent a4fcf451f5
commit 363d783f42
1 changed files with 4 additions and 2 deletions

View File

@ -12,8 +12,10 @@ module.exports = async (callback) => {
const [account,] = await web3.eth.getAccounts();
const wrappedBalance1 = await wrapper.balanceOf(account, nftId1);
const tokenBalance1 = await tokenContract1.balanceOf(account);
const whom = process.argv[7] ? process.argv[7] : account;
const wrappedBalance1 = await wrapper.balanceOf(whom, nftId1);
const tokenBalance1 = await tokenContract1.balanceOf(whom);
console.log(`Wrapped: ${wrappedBalance1}`);
console.log(`Unwrapped: ${tokenBalance1}`);