diff --git a/package.json b/package.json index cac7c93f..2db1abd3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@airdao/airdao-node-contracts", - "version": "1.0.10", + "version": "1.0.11", "main": "./dist/src/index.js", "files": [ "dist/**/*" diff --git a/src/multisig/methods/staking.ts b/src/multisig/methods/staking.ts index 620b72c7..8af4e76c 100644 --- a/src/multisig/methods/staking.ts +++ b/src/multisig/methods/staking.ts @@ -116,8 +116,9 @@ export async function rewardsBanksWithdrawBonds( addressTo: string, amount: BigNumberish ) { + const airBond = contracts.getContractByName(ContractNames.AirBond) as AirBond; return await submitTransaction2(contracts, contractName, 0, (rewardsBank) => - rewardsBank.withdrawBonds(addressTo, amount) + rewardsBank.withdrawErc20(airBond.address, addressTo, amount) ); } @@ -144,7 +145,7 @@ export async function getAmbBalance(contracts: Contracts, contractName: Contract } export async function getBondsBalance(contracts: Contracts, contractName: ContractNames) { - const contract = contracts.getContractByName(contractName) as AirBond; - const airBond = contracts.getContractByName(ContractNames.AirBond); - return await airBond.getBalance(contract.address); + const contract = contracts.getContractByName(contractName); + const airBond = contracts.getContractByName(ContractNames.AirBond) as AirBond; + return await airBond.balanceOf(contract.address); }