diff --git a/src/components/swaptab/index.js b/src/components/swaptab/index.js index ff3e9a3..699c607 100644 --- a/src/components/swaptab/index.js +++ b/src/components/swaptab/index.js @@ -276,8 +276,12 @@ class SwapTab extends React.Component { }; updateQuoteAmount = baseAmount => { - const { rate } = this.state.rate; - const fee = this.calculateFee(baseAmount); + const { rate, orderSide } = this.state.rate; + let fee = this.calculateFee(baseAmount); + + if (orderSide === 'sell') { + fee = fee * rate; + } const quote = Number((baseAmount * rate - fee).toFixed(8));