Skip to content

Commit

Permalink
Merge pull request #11023 from brave/pr11001_f/wallet/swap-config_1.33.x
Browse files Browse the repository at this point in the history
chore(wallet): do not provide swap config to backend (uplift to 1.33.x)
  • Loading branch information
kjozwiak authored Nov 12, 2021
2 parents 05ba412 + bae2e3d commit 8639214
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 34 deletions.
5 changes: 0 additions & 5 deletions components/brave_wallet_ui/common/async/handlers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ import {
TransactionStatus
} from '../../constants/types'
import { toWeiHex } from '../../utils/format-balances'
import getSwapConfig from '../../constants/swap.config'
import { hexStrToNumberArray } from '../../utils/hex-utils'
import getAPIProxy from './bridge'
import {
Expand Down Expand Up @@ -449,17 +448,13 @@ export const fetchSwapQuoteFactory = (
full
} = payload

const config = getSwapConfig(payload.networkChainId)

const swapParams = {
takerAddress: accountAddress,
sellAmount: fromAssetAmount || '',
buyAmount: toAssetAmount || '',
buyToken: toAsset.asset.contractAddress || toAsset.asset.symbol,
sellToken: fromAsset.asset.contractAddress || fromAsset.asset.symbol,
buyTokenPercentageFee: config.buyTokenPercentageFee,
slippagePercentage: slippageTolerance.slippage / 100,
feeRecipient: config.feeRecipient,
gasPrice: ''
}

Expand Down
29 changes: 0 additions & 29 deletions components/brave_wallet_ui/constants/swap.config.ts

This file was deleted.

0 comments on commit 8639214

Please sign in to comment.