Skip to content

Commit

Permalink
fix(router): add card expiry check in the network_transaction_id_and_…
Browse files Browse the repository at this point in the history
…card_details based mit flow
  • Loading branch information
ShankarSinghC committed Nov 7, 2024
1 parent cf126b9 commit 3283d94
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions crates/router/src/core/payments.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4464,6 +4464,11 @@ where

let (mandate_reference_id, card_details_for_network_transaction_id)= hyperswitch_domain_models::payment_method_data::CardDetailsForNetworkTransactionId::get_nti_and_card_details_for_mit_flow(recurring_payment_details.clone()).get_required_value("network transaction id and card details").attach_printable("Failed to fetch network transaction id and card details for mit")?;

helpers::validate_card_expiry(
&card_details_for_network_transaction_id.card_exp_month,
&card_details_for_network_transaction_id.card_exp_year,
)?;

let network_transaction_id_supported_connectors = &state
.conf
.network_transaction_id_supported_connectors
Expand Down

0 comments on commit 3283d94

Please sign in to comment.