From ae6d57ec59e572fe1a70660b439542bed4cba91d Mon Sep 17 00:00:00 2001 From: ashish-egov Date: Thu, 25 Jul 2024 14:18:08 +0530 Subject: [PATCH] fix kafka --- .../project-factory/src/server/utils/campaignMappingUtils.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/utilities/project-factory/src/server/utils/campaignMappingUtils.ts b/utilities/project-factory/src/server/utils/campaignMappingUtils.ts index a367708be16..5219ad4fcb2 100644 --- a/utilities/project-factory/src/server/utils/campaignMappingUtils.ts +++ b/utilities/project-factory/src/server/utils/campaignMappingUtils.ts @@ -427,7 +427,10 @@ export async function processMapping(mappingObject: any) { } logger.info("Mapping completed successfully for campaign: " + mappingObject?.CampaignDetails?.id); mappingObject.CampaignDetails.status = campaignStatuses.inprogress - produceModifiedMessages(mappingObject, config?.kafka?.KAFKA_UPDATE_PROJECT_CAMPAIGN_DETAILS_TOPIC) + const produceMessage: any = { + CampaignDetails: mappingObject?.CampaignDetails + } + produceModifiedMessages(produceMessage, config?.kafka?.KAFKA_UPDATE_PROJECT_CAMPAIGN_DETAILS_TOPIC) await persistTrack(mappingObject?.CampaignDetails?.id, processTrackTypes.campaignCreation, processTrackStatuses.completed) } catch (error) { logger.error("Error in campaign mapping: " + error);