diff --git a/crates/router/src/core/errors/transformers.rs b/crates/router/src/core/errors/transformers.rs index a566b5c3dd7..c3de732bc11 100644 --- a/crates/router/src/core/errors/transformers.rs +++ b/crates/router/src/core/errors/transformers.rs @@ -191,7 +191,7 @@ impl ErrorSwitch for ApiErrorRespon message, reason, .. - } => AER::GenericError(ApiError::new("HE", 3, format!("{message}"), Some(Extra { reason: Some(reason.clone()), ..Default::default() }))), + } => AER::GenericError(ApiError::new("HE", 3, message, Some(Extra { reason: Some(reason.clone()), ..Default::default() }))), Self::SuccessfulPaymentNotFound => { AER::NotFound(ApiError::new("HE", 4, "Successful payment not found for the given payment id", None)) }