diff --git a/src/shared/sandboxCommandBase.ts b/src/shared/sandboxCommandBase.ts index f4575129..84b3de53 100644 --- a/src/shared/sandboxCommandBase.ts +++ b/src/shared/sandboxCommandBase.ts @@ -76,8 +76,8 @@ export abstract class SandboxCommandBase extends SfCommand { // if user hasn't opted out of tracking, and sandbox type supports it, verify that prod org supports tracking-enabled sandboxes const sourceTrackingSettings = await this.prodOrg .getConnection() - .metadata.read('SourceTrackingSettings', 'SourceTrackingSettings'); - if (sourceTrackingSettings.enableSourceTrackingSandboxes !== true) { + .singleRecordQuery('SELECT IsSourceTrackingSandboxesEnabled FROM SourceTrackingSettings', { tooling: true }); + if (sourceTrackingSettings?.IsSourceTrackingSandboxesEnabled !== true) { return false; } }