Skip to content

Commit a72524d

Browse files
authored
Merge pull request #380 from sf-aastha-paruthi/u/aparuthi/generalConsetFix
@W-19312635 Consent Fix for related objects
2 parents 18f6c8f + b79ad01 commit a72524d

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

messages/migrate.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,5 +231,6 @@
231231
"checkingStandardDesignerStatus": "Checking if standard designer is already enabled for package: %s",
232232
"enableStandardRuntimeAfterDesigner": "Standard designer setup successful, proceeding with Standard Runtime enablement",
233233
"skipStandardRuntimeDueToFailure": "Skipping Standard Runtime enablement due to designer setup failure",
234-
"errorCheckingStandardDesigner": "Failed to check standard designer status for package %s: %s"
234+
"errorCheckingStandardDesigner": "Failed to check standard designer status for package %s: %s",
235+
"relatedObjectsConsentNotGiven": "The related objects will not be processed because the user declined consent."
235236
}

src/commands/omnistudio/migration/migrate.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -285,9 +285,10 @@ export default class Migrate extends OmniStudioBaseCommand {
285285
isExperienceBundleMetadataAPIProgramaticallyEnabled
286286
);
287287
deploymentConfig = await preMigrate.getAutoDeployConsent(objectsToProcess.includes(Constants.LWC), actionItems);
288-
Logger.logVerbose(
289-
'The objects to process after handleExpSitePrerequisite are ' + JSON.stringify(objectsToProcess)
290-
);
288+
} else {
289+
objectsToProcess.length = 0;
290+
Logger.warn(messages.getMessage('relatedObjectsConsentNotGiven'));
291+
Logger.logVerbose(messages.getMessage('relatedObjectsToProcess', [JSON.stringify(objectsToProcess)]));
291292
}
292293

293294
return { objectsToProcess, projectPath, targetApexNamespace, deploymentConfig };

0 commit comments

Comments
 (0)