From 8d440b0e905196d7c10eec9b01487fc793bc8453 Mon Sep 17 00:00:00 2001 From: Dmytro Danylov Date: Sun, 8 Oct 2023 03:12:14 +0300 Subject: [PATCH] refactor(connector): Use connector_request_reference_id for Shift4 --- crates/router/src/connector/shift4/transformers.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/crates/router/src/connector/shift4/transformers.rs b/crates/router/src/connector/shift4/transformers.rs index 23c91e48d8ca..0dd3b8583490 100644 --- a/crates/router/src/connector/shift4/transformers.rs +++ b/crates/router/src/connector/shift4/transformers.rs @@ -717,6 +717,7 @@ impl types::PaymentsResponseData, >, ) -> Result { + let connector_id = types::ResponseId::ConnectorTransactionId(item.response.id.clone()); Ok(Self { status: enums::AttemptStatus::foreign_from(( item.response.captured, @@ -727,7 +728,7 @@ impl item.response.status, )), response: Ok(types::PaymentsResponseData::TransactionResponse { - resource_id: types::ResponseId::ConnectorTransactionId(item.response.id), + resource_id: connector_id, redirection_data: item .response .flow @@ -737,7 +738,7 @@ impl mandate_reference: None, connector_metadata: None, network_txn_id: None, - connector_response_reference_id: None, + connector_response_reference_id: Some(item.response.id), }), ..item.data })