From 9f5f29513c01b0ef8c098522f5ce690c09c4a859 Mon Sep 17 00:00:00 2001 From: Sale Djenic Date: Thu, 7 Nov 2024 15:04:37 +0100 Subject: [PATCH] fix(wallet)_: broken swap and bridge for erc20 tokens fixed --- services/wallet/responses/router_transactions.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/services/wallet/responses/router_transactions.go b/services/wallet/responses/router_transactions.go index d1c25246b..be26dcc56 100644 --- a/services/wallet/responses/router_transactions.go +++ b/services/wallet/responses/router_transactions.go @@ -48,6 +48,7 @@ type RouterSentTransaction struct { FromToken string `json:"fromToken"` ToToken string `json:"toToken"` Amount string `json:"amount"` // amount sent + AmountIn string `json:"amountIn"` // amount that is "data" of tx (important for erc20 tokens) AmountOut string `json:"amountOut"` // amount that will be received Hash types.Hash `json:"hash"` ApprovalTx bool `json:"approvalTx"` @@ -80,6 +81,7 @@ func NewRouterSentTransaction(sendArgs *wallettypes.SendTxArgs, hash types.Hash, FromToken: sendArgs.FromTokenID, ToToken: sendArgs.ToTokenID, Amount: sendArgs.Value.String(), + AmountIn: sendArgs.ValueIn.String(), AmountOut: sendArgs.ValueOut.String(), Hash: hash, ApprovalTx: approvalTx,