diff --git a/crates/router/src/connector/paypal/transformers.rs b/crates/router/src/connector/paypal/transformers.rs index a26317fe679b..21b0f04af86b 100644 --- a/crates/router/src/connector/paypal/transformers.rs +++ b/crates/router/src/connector/paypal/transformers.rs @@ -23,9 +23,6 @@ use crate::{ }, }; -#[cfg(feature = "payouts")] -const LANGUAGE: &str = "en-US"; - #[derive(Debug, Serialize)] pub struct PaypalRouterData { pub amount: String, @@ -1616,7 +1613,7 @@ impl TryFrom<&PaypalRouterData<&types::PayoutsRouterData>> for P amount, payout_method_data, note: item.router_data.description.to_owned(), - notification_language: LANGUAGE.to_string(), + notification_language: consts::DEFAULT_NOTIFICATION_SCRIPT_LANGUAGE.to_string(), }) } } diff --git a/crates/router/src/consts.rs b/crates/router/src/consts.rs index 2c4ec3f5e70b..9a975a3d462f 100644 --- a/crates/router/src/consts.rs +++ b/crates/router/src/consts.rs @@ -38,6 +38,7 @@ pub(crate) const LOW_BALANCE_ERROR_MESSAGE: &str = "Insufficient balance in the pub(crate) const CONNECTOR_UNAUTHORIZED_ERROR: &str = "Authentication Error from the connector"; pub(crate) const CANNOT_CONTINUE_AUTH: &str = "Cannot continue with Authorization due to failed Liability Shift."; +pub(crate) const DEFAULT_NOTIFICATION_SCRIPT_LANGUAGE: &str = "en-US"; // General purpose base64 engines pub(crate) const BASE64_ENGINE: base64::engine::GeneralPurpose = diff --git a/crates/router/src/core/payment_methods/vault.rs b/crates/router/src/core/payment_methods/vault.rs index f9c618d1dd29..be7ceabab75e 100644 --- a/crates/router/src/core/payment_methods/vault.rs +++ b/crates/router/src/core/payment_methods/vault.rs @@ -421,7 +421,7 @@ impl Vaultable for api::CardPayout { pub struct TokenizedWalletSensitiveValues { pub email: Option, pub telephone_number: Option>, - pub paypal_id: Option>, + pub wallet_id: Option>, pub wallet_type: PaymentMethodType, } @@ -437,13 +437,13 @@ impl Vaultable for api::WalletPayout { Self::Paypal(paypal_data) => TokenizedWalletSensitiveValues { email: paypal_data.email.clone(), telephone_number: paypal_data.telephone_number.clone(), - paypal_id: paypal_data.paypal_id.clone(), + wallet_id: paypal_data.paypal_id.clone(), wallet_type: PaymentMethodType::Paypal, }, Self::Venmo(venmo_data) => TokenizedWalletSensitiveValues { email: None, telephone_number: venmo_data.telephone_number.clone(), - paypal_id: None, + wallet_id: None, wallet_type: PaymentMethodType::Venmo, }, }; @@ -481,7 +481,7 @@ impl Vaultable for api::WalletPayout { PaymentMethodType::Paypal => Self::Paypal(api_models::payouts::Paypal { email: value1.email, telephone_number: value1.telephone_number, - paypal_id: value1.paypal_id, + paypal_id: value1.wallet_id, }), PaymentMethodType::Venmo => Self::Venmo(api_models::payouts::Venmo { telephone_number: value1.telephone_number,