Skip to content

Commit

Permalink
Add check error when burn remaining coin
Browse files Browse the repository at this point in the history
  • Loading branch information
neitdung committed Jan 29, 2024
1 parent 93308b5 commit 434af1d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion x/multi-staking/keeper/abci.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,10 @@ func (k Keeper) BurnUnbondedCoinAndUnlockedMultiStakingCoin(
}
// burn remaining coin in unlock
remaningCoin := unlockEntry.UnlockingCoin.ToCoin().Sub(unlockedCoin)
k.bankKeeper.BurnCoins(ctx, types.ModuleName, sdk.NewCoins(remaningCoin))
err = k.bankKeeper.BurnCoins(ctx, types.ModuleName, sdk.NewCoins(remaningCoin))
if err != nil {
return sdk.Coin{}, err
}

err = k.UnescrowCoinTo(ctx, multiStakerAddr, unlockedCoin)
if err != nil {
Expand Down

0 comments on commit 434af1d

Please sign in to comment.