From b6a33089c8fa0f965705d9ed11df6b889115b0f1 Mon Sep 17 00:00:00 2001 From: Anthony Laibe Date: Fri, 20 Jan 2023 10:25:49 +0100 Subject: [PATCH] fix: ensure bonder fees are lower than amount --- services/wallet/router.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/services/wallet/router.go b/services/wallet/router.go index bf1434dd6..8d4a6f4b7 100644 --- a/services/wallet/router.go +++ b/services/wallet/router.go @@ -555,6 +555,10 @@ func (r *Router) suggestedRoutes( continue } + if bonderFees.Cmp(maxAmountIn.ToInt()) >= 0 { + continue + } + gasLimit := uint64(0) if sendType.isTransfer() { gasLimit, err = bridge.EstimateGas(network, dest, token, amountIn)