Open source, composable payments platform | PCI compliant | SaaS and Self-host options | Enables connectivity to multiple payment, payout, fraud, vault and tokenization providers | Uplifts authorization with intelligent routing and revenue recovery | Reduce payment processing costs with cost observability | Reduces payment ops with reconciliation
Rust adyenbeginner-friendlyfeaturedfinancefintechhacktoberfesthigh-performanceopen-sourceorchestrationpaymentpayment-gatewaypayment-integrationpayment-processingpaymentspayments-platformrestful-apirustsdkstripeworks-with-react
fix(payment-methods): never execute legacy PM update path for modular flow (#14976)
Kashif409394a07384
diff --git a/crates/router/src/core/payments.rs b/crates/router/src/core/payments.rsindex 86dd212e10..fb198a0474 100644--- a/crates/router/src/core/payments.rs+++ b/crates/router/src/core/payments.rs@@ -2995,13 +2995,16 @@ where"resolving modular vs legacy payment method update path");- if payment_data.get_payment_method_info().is_some_and(|pm| {- feature_config.should_use_modular_pm_path(- Some(pm.version),- pm.compatibility_updated_at,- Some(pm.last_modified),- )- }) {+ if payment_data.get_payment_method_info().map_or(+ feature_config.is_payment_method_modular_allowed,+ |pm| {+ feature_config.should_use_modular_pm_path(+ Some(pm.version),+ pm.compatibility_updated_at,+ Some(pm.last_modified),+ )+ },+ ) {logger::info!(payment_id = ?payment_data.get_payment_attempt().payment_id,"Modular payment method path selected; calling update_modular_pm_and_mandate"