Skip to content

Commit

Permalink
refactor(connector): [Iatapay] remove default case handling (#2587)
Browse files Browse the repository at this point in the history
Co-authored-by: Prasunna Soppa <[email protected]>
  • Loading branch information
HeetVekariya and prasunna09 authored Oct 19, 2023
1 parent 1f2fe51 commit 6494e8a
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion crates/router/src/connector/iatapay/transformers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,18 @@ impl TryFrom<&types::PaymentsAuthorizeRouterData> for IatapayPaymentsRequest {
let payment_method = item.payment_method;
let country = match payment_method {
PaymentMethod::Upi => "IN".to_string(),
_ => item.get_billing_country()?.to_string(),

PaymentMethod::Card
| PaymentMethod::CardRedirect
| PaymentMethod::PayLater
| PaymentMethod::Wallet
| PaymentMethod::BankRedirect
| PaymentMethod::BankTransfer
| PaymentMethod::Crypto
| PaymentMethod::BankDebit
| PaymentMethod::Reward
| PaymentMethod::Voucher
| PaymentMethod::GiftCard => item.get_billing_country()?.to_string(),
};
let return_url = item.get_return_url()?;
let payer_info = match item.request.payment_method_data.clone() {
Expand Down

0 comments on commit 6494e8a

Please sign in to comment.