diff --git a/crates/router/src/core/payments/operations/payment_reject.rs b/crates/router/src/core/payments/operations/payment_reject.rs index 7321200a30ad..23531d2342dc 100644 --- a/crates/router/src/core/payments/operations/payment_reject.rs +++ b/crates/router/src/core/payments/operations/payment_reject.rs @@ -265,8 +265,8 @@ impl UpdateTracker, PaymentsCancelRequest> for Payme ) .await .to_not_found_response(errors::ApiErrorResponse::PaymentNotFound)?; - let error_code = payment_data.payment_attempt.error_code; - let error_message = payment_data.payment_attempt.error_message; + let error_code = payment_data.payment_attempt.error_code.clone(); + let error_message = payment_data.payment_attempt.error_message.clone(); req_state .event_context .event(AuditEvent::new(AuditEventType::PaymentReject {