Skip to content

Commit

Permalink
feat: paymentMethodId comments from PR review
Browse files Browse the repository at this point in the history
  • Loading branch information
Sean Han committed Dec 15, 2021
1 parent 93a7fc1 commit 4ade34a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,13 @@ import {
import * as S from './selectors'
import { actions as A } from './slice'
import * as T from './types'
import { getDirection, getPreferredCurrency, reversePair, setPreferredCurrency } from './utils'
import {
BANK_TRANSFER_PAYMENT_METHOD_ID,
getDirection,
getPreferredCurrency,
reversePair,
setPreferredCurrency
} from './utils'

export const logLocation = 'components/buySell/sagas'

Expand Down Expand Up @@ -832,8 +838,9 @@ export default ({ api, coreSagas, networks }: { api: APIType; coreSagas: any; ne
const pairReversed = reversePair(pair)
let paymentMethodId: string | undefined

// paymentMethodId is required when profile=SIMPLEBUY and paymentMethod=BANK_TRANSFER
if (paymentMethod === BSPaymentTypes.BANK_TRANSFER) {
paymentMethodId = 'd74992e0-a462-4aeb-903e-fc8e9a11bb40'
paymentMethodId = BANK_TRANSFER_PAYMENT_METHOD_ID
}

const quote: ReturnType<typeof api.getBuyQuote> = yield call(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,6 @@ export const reversePair = (pair: string) => {

return pairReversed
}

// paymentMethodId is required when profile=SIMPLEBUY and paymentMethod=BANK_TRANSFER
export const BANK_TRANSFER_PAYMENT_METHOD_ID = 'd74992e0-a462-4aeb-903e-fc8e9a11bb40'

0 comments on commit 4ade34a

Please sign in to comment.