refactor(payment_methods): added clone derivation for PaymentMethodId (#1568)

Co-authored-by: Sarthak Soni <sarthak.soni@juspay.in>
Co-authored-by: Sampras Lopes <lsampras@protonmail.com>
This commit is contained in:
Sarthak Soni
2023-07-03 15:07:33 +05:30
committed by GitHub
parent 44b8da430c
commit 6739b59bc8
2 changed files with 3 additions and 3 deletions

View File

@ -93,7 +93,7 @@ pub struct CustomerResponse {
pub metadata: Option<pii::SecretSerdeValue>, pub metadata: Option<pii::SecretSerdeValue>,
} }
#[derive(Default, Debug, Deserialize, Serialize)] #[derive(Default, Clone, Debug, Deserialize, Serialize)]
pub struct CustomerId { pub struct CustomerId {
pub customer_id: String, pub customer_id: String,
} }

View File

@ -293,7 +293,7 @@ pub struct RequestPaymentMethodTypes {
} }
//List Payment Method //List Payment Method
#[derive(Debug, serde::Serialize, Default, ToSchema)] #[derive(Debug, Clone, serde::Serialize, Default, ToSchema)]
#[serde(deny_unknown_fields)] #[serde(deny_unknown_fields)]
pub struct PaymentMethodListRequest { pub struct PaymentMethodListRequest {
/// This is a 15 minute expiry token which shall be used from the client to authenticate and perform sessions from the SDK /// This is a 15 minute expiry token which shall be used from the client to authenticate and perform sessions from the SDK
@ -543,7 +543,7 @@ pub struct CustomerPaymentMethod {
#[serde(default, with = "common_utils::custom_serde::iso8601::option")] #[serde(default, with = "common_utils::custom_serde::iso8601::option")]
pub created: Option<time::PrimitiveDateTime>, pub created: Option<time::PrimitiveDateTime>,
} }
#[derive(Debug, serde::Serialize, serde::Deserialize)] #[derive(Debug, Clone, serde::Serialize, serde::Deserialize)]
pub struct PaymentMethodId { pub struct PaymentMethodId {
pub payment_method_id: String, pub payment_method_id: String,
} }