Skip to content

Commit

Permalink
fix(router): handle default case for card_network for co-badged cards (
Browse files Browse the repository at this point in the history
  • Loading branch information
Sakilmostak authored Dec 16, 2024
1 parent ae00a10 commit f95ee51
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions crates/router/src/core/payments/helpers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4433,7 +4433,7 @@ pub async fn get_additional_payment_data(
api_models::payments::AdditionalPaymentData::Card(Box::new(
api_models::payments::AdditionalCardInfo {
card_issuer: card_info.card_issuer,
card_network: card_network.or(card_info.card_network),
card_network: card_network.clone().or(card_info.card_network),
bank_code: card_info.bank_code,
card_type: card_info.card_type,
card_issuing_country: card_info.card_issuing_country,
Expand All @@ -4453,7 +4453,7 @@ pub async fn get_additional_payment_data(
api_models::payments::AdditionalPaymentData::Card(Box::new(
api_models::payments::AdditionalCardInfo {
card_issuer: None,
card_network: None,
card_network,
bank_code: None,
card_type: None,
card_issuing_country: None,
Expand Down Expand Up @@ -4696,7 +4696,7 @@ pub async fn get_additional_payment_data(
api_models::payments::AdditionalPaymentData::Card(Box::new(
api_models::payments::AdditionalCardInfo {
card_issuer: card_info.card_issuer,
card_network: card_network.or(card_info.card_network),
card_network: card_network.clone().or(card_info.card_network),
bank_code: card_info.bank_code,
card_type: card_info.card_type,
card_issuing_country: card_info.card_issuing_country,
Expand All @@ -4716,7 +4716,7 @@ pub async fn get_additional_payment_data(
api_models::payments::AdditionalPaymentData::Card(Box::new(
api_models::payments::AdditionalCardInfo {
card_issuer: None,
card_network: None,
card_network,
bank_code: None,
card_type: None,
card_issuing_country: None,
Expand Down

0 comments on commit f95ee51

Please sign in to comment.