diff --git a/utils/getTrustedCertificates.ts b/utils/getTrustedCertificates.ts index 433a58299d..b2cfebf97b 100644 --- a/utils/getTrustedCertificates.ts +++ b/utils/getTrustedCertificates.ts @@ -32,8 +32,10 @@ export async function getTrustedCertificates(): Promise<(string | Buffer)[]> { this.suppressTelemetry = true; let importSetting = vscode.workspace.getConfiguration('docker').get('importCertificates'); - if (importSetting === false) { - // Use default Node.js behavior + + // If value is false or null/undefined or anything not an object or boolean... + if (!importSetting || (typeof importSetting !== "object" && typeof importSetting !== "boolean")) { + // ... then use default Node.js behavior this.properties.importCertificates = 'false'; return undefined; }