Skip to content

Commit

Permalink
fix: Select customer card with Adyen
Browse files Browse the repository at this point in the history
  • Loading branch information
acasazza committed Feb 24, 2022
1 parent 7d40ac4 commit f2cc9c3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/reducers/PaymentMethodReducer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ type Card = {

export type PaymentSourceObject = {
adyen_payments: AdyenPayment & {
paymentRequestData?: {
paymentMethod?: Card
payment_request_data?: {
payment_method?: Card
}
}
braintree_payments: BraintreePayment & {
Expand Down
2 changes: 1 addition & 1 deletion src/utils/getCardDetails.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export default function getCardDetails({
case 'adyen_payments': {
const ps =
customerPayment.payment_source as PaymentSourceObject[typeof paymentType]
const source = ps?.paymentRequestData?.paymentMethod
const source = ps?.payment_request_data?.payment_method
if (source) {
return {
...source,
Expand Down

0 comments on commit f2cc9c3

Please sign in to comment.