Skip to content
This repository has been archived by the owner on Apr 25, 2024. It is now read-only.

Commit

Permalink
Fix code style issues with Prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
lint-action committed Sep 8, 2023
1 parent 178f8dc commit d170c29
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions src/entities/pair.ts
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,8 @@ export class Pair {
const inputAmountWithFee = JSBI.multiply(inputAmount.quotient, _997)

const inputAmountWithFeeAndTax = this.deriveInputAmountWithTax(
CurrencyAmount.fromRawAmount(inputAmount.currency, inputAmountWithFee));
CurrencyAmount.fromRawAmount(inputAmount.currency, inputAmountWithFee)
)

const numerator = JSBI.multiply(inputAmountWithFeeAndTax.quotient, outputReserve.quotient)
const denominator = JSBI.add(JSBI.multiply(inputReserve.quotient, _1000), inputAmountWithFeeAndTax.quotient)
Expand Down Expand Up @@ -327,10 +328,7 @@ export class Pair {
if (sellFeeBips) {
const sellFeePercentInDecimal = JSBI.divide(JSBI.BigInt(inputAmount.currency.sellFeeBps), JSBI.BigInt(10000))
const taxAmount = JSBI.multiply(inputAmount.quotient, sellFeePercentInDecimal)
return CurrencyAmount.fromRawAmount(
inputAmount.currency,
JSBI.subtract(inputAmount.quotient, taxAmount)
);
return CurrencyAmount.fromRawAmount(inputAmount.currency, JSBI.subtract(inputAmount.quotient, taxAmount))
} else {
return inputAmount
}
Expand All @@ -341,10 +339,7 @@ export class Pair {
if (buyFeeBps) {
const buyFeePercentInDecimal = JSBI.divide(JSBI.BigInt(outputAmount.currency.buyFeeBps), JSBI.BigInt(10000))
const taxAmount = JSBI.multiply(outputAmount.quotient, buyFeePercentInDecimal)
return CurrencyAmount.fromRawAmount(
outputAmount.currency,
JSBI.subtract(outputAmount.quotient, taxAmount)
)
return CurrencyAmount.fromRawAmount(outputAmount.currency, JSBI.subtract(outputAmount.quotient, taxAmount))
} else {
return outputAmount
}
Expand Down

0 comments on commit d170c29

Please sign in to comment.