Skip to content

Commit

Permalink
Add helpful comments
Browse files Browse the repository at this point in the history
  • Loading branch information
yorhodes committed Oct 5, 2021
1 parent 03e17ab commit 126d03c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/cli/src/commands/releasegold/admin-revoke.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ export default class AdminRevoke extends ReleaseGoldBaseCommand {
)
}

// rescue any cUSD balance
const stabletoken = await this.kit.contracts.getStableToken()
const cusdBalance = await stabletoken.balanceOf(this.contractAddress)
if (cusdBalance.isGreaterThan(0)) {
Expand All @@ -128,6 +129,7 @@ export default class AdminRevoke extends ReleaseGoldBaseCommand {
)
}

// attempt to refund and finalize, surface pending withdrawals
const remainingLockedGold = await this.releaseGoldWrapper.getRemainingLockedBalance()
if (remainingLockedGold.isZero()) {
await displaySendTx(
Expand Down

0 comments on commit 126d03c

Please sign in to comment.