Skip to content

Commit

Permalink
feat(pricing): remove logs
Browse files Browse the repository at this point in the history
  • Loading branch information
Sean Han committed Dec 14, 2021
1 parent 2009699 commit 5136679
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,8 @@ export default ({ api, coreSagas, networks }: { api: APIType; coreSagas: any; ne
const buyQuote = isFlexiblePricingModel
? S.getBuyQuote(yield select()).getOrFail(NO_QUOTE)
: undefined
// TODO: @sean @pricing remove log
// eslint-disable-next-line
console.log('buyQuote() redux state', buyQuote)

if (!values) throw new Error(NO_CHECKOUT_VALUES)
Expand Down Expand Up @@ -1112,6 +1114,8 @@ export default ({ api, coreSagas, networks }: { api: APIType; coreSagas: any; ne
if (!pair) throw new Error(NO_PAIR_SELECTED)
// Fetch rates
if (orderType === OrderType.BUY) {
// TODO: @sean @pricing remove log
// eslint-disable-next-line
console.log('amount/pair before buyQuote: ', amount, pair)
const isFlexiblePricingModel = (yield select(
selectors.core.walletOptions.getFlexiblePricingModel
Expand All @@ -1120,6 +1124,8 @@ export default ({ api, coreSagas, networks }: { api: APIType; coreSagas: any; ne
if (isFlexiblePricingModel) {
const pairArr = pair.pair.split('-')
const pairReversed = `${pairArr[1]}-${pairArr[0]}`
// TODO: @sean @pricing remove log
// eslint-disable-next-line
console.log('pair reversed', pairReversed)
// TODO: the below code is breaking @pricing @sean
// yield put(A.fetchBuyQuote({ amount: '0', pair: pairReversed }))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,6 @@ export default ({ api, coreSagas, networks }: { api: APIType; coreSagas; network
const amount = convertStandardToBase(BASE.coin, swapAmountFormValues.cryptoAmount)

const quote = S.getQuote(yield select()).getOrFail('NO_SWAP_QUOTE')
// eslint-disable-next-line no-console
console.log('[quote]: ', quote)
const refundAddr = onChain ? yield call(selectReceiveAddress, BASE, networks) : undefined
const destinationAddr = toChain
? yield call(selectReceiveAddress, COUNTER, networks)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ const { FORM_BS_CHECKOUT } = model.components.buySell
const getData = (state: RootState, ownProps: OwnProps) => {
const coin = selectors.components.buySell.getCryptoCurrency(state) || 'BTC'
const formErrors = selectors.form.getFormSyncErrors(FORM_BS_CHECKOUT)(state)
console.log('formErrors: ', formErrors)
// used for sell only now, eventually buy as well
// TODO: use swap2 quote for buy AND sell
const paymentR = selectors.components.buySell.getPayment(state)
Expand Down

0 comments on commit 5136679

Please sign in to comment.