Skip to content

Commit

Permalink
chore: update condition
Browse files Browse the repository at this point in the history
  • Loading branch information
nvtaveras committed Oct 16, 2023
1 parent aec728f commit c573c89
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/features/swap/SwapConfirm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,10 @@ export function SwapConfirmCard({ formValues }: Props) {
return
}
const rateBN = new BigNumber(rate)
if (
(toTokenId || fromTokenId) !== 'eXOF' &&
(rateBN.lt(MIN_EXCHANGE_RATE) || rateBN.gt(MAX_EXCHANGE_RATE))
) {

// ignore eXOF for now until we have a better way to handle it
const tradeHasEXOF = toTokenId === 'eXOF' || fromTokenId === 'eXOF'
if (!tradeHasEXOF && (rateBN.lt(MIN_EXCHANGE_RATE) || rateBN.gt(MAX_EXCHANGE_RATE))) {
toast.error('Rate seems incorrect')
return
}
Expand Down

0 comments on commit c573c89

Please sign in to comment.