Skip to content

Commit

Permalink
change check
Browse files Browse the repository at this point in the history
  • Loading branch information
lumtis committed Oct 16, 2023
1 parent 67b7fdd commit ec2b399
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions x/crosschain/keeper/gas_payment.go
Original file line number Diff line number Diff line change
Expand Up @@ -227,9 +227,9 @@ func (k Keeper) PayGasInERC20AndUpdateCctx(
// https://github.com/zeta-chain/node/issues/1303
// check if the final gas received after swap matches the gas fee defined
// if not there might be issues with the pool liquidity and it is safer from an accounting perspective to return an error
//if gasObtained.Cmp(outTxGasFee.BigInt()) != 0 {
// return cosmoserrors.Wrapf(types.ErrInvalidGasAmount, "gas obtained for burn (%s) not equal to gas fee(%s)", gasObtained, outTxGasFee)
//}
if gasObtained.Cmp(outTxGasFee.BigInt()) == -1 {
return cosmoserrors.Wrapf(types.ErrInvalidGasAmount, "gas obtained for burn (%s) is lower than gas fee(%s)", gasObtained, outTxGasFee)
}

// burn the gas ZRC20
err = k.fungibleKeeper.CallZRC20Burn(ctx, types.ModuleAddressEVM, gasZRC20, gasObtained, noEthereumTxEvent)
Expand Down

0 comments on commit ec2b399

Please sign in to comment.