Skip to content

fix: missing asset pricing on re-submission of swap transaction

Anthony Alviz requested to merge anthony/resubmit_txn_missing_pricing into master

Previous Behavior:

  • Re-submitting a pending transaction WILL cause the "missing pricing" modal to show

This is due to only sending pricing for 1 asset to the swap quotes route.

New Behavior:

  • Re-submitting a pending transaction WILL NOT cause the "missing pricing" modal to show

This was achieved by:

  1. Pass through pricing of both assets swapping into swap confirmation screen
  2. Store pricing of both assets into transactions
  3. Pending transaction re-submission will propagate pricing of both assets to avoid getting missing pricing modal

Note: If the transaction previously did not store pricing for both assets (or simply just missing), we grab that USD value from the transaction detail toToken.usdValue and fromToken.usdValue

Merge request reports