Skip to content

Commit

Permalink
Fix sdk
Browse files Browse the repository at this point in the history
  • Loading branch information
SvineruS committed Aug 4, 2023
1 parent 40a3ad5 commit 1c5a92f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@airdao/airdao-node-contracts",
"version": "1.0.10",
"version": "1.0.11",
"main": "./dist/src/index.js",
"files": [
"dist/**/*"
Expand Down
9 changes: 5 additions & 4 deletions src/multisig/methods/staking.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,9 @@ export async function rewardsBanksWithdrawBonds(
addressTo: string,
amount: BigNumberish
) {
const airBond = contracts.getContractByName(ContractNames.AirBond) as AirBond;
return await submitTransaction2<RewardsBank>(contracts, contractName, 0, (rewardsBank) =>
rewardsBank.withdrawBonds(addressTo, amount)
rewardsBank.withdrawErc20(airBond.address, addressTo, amount)
);
}

Expand All @@ -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);
}

0 comments on commit 1c5a92f

Please sign in to comment.