@salesforce/core 8.8.4 → 8.8.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -143,7 +143,7 @@ class AliasAccessor extends kit_1.AsyncOptionalCreatable {
|
|
|
143
143
|
this.aliasStore = fileContentsRawToAliasStore(await (0, promises_1.readFile)(this.fileLocation, 'utf-8'));
|
|
144
144
|
}
|
|
145
145
|
catch (e) {
|
|
146
|
-
if (e instanceof Error && 'code' in e && e.code === 'ENOENT') {
|
|
146
|
+
if (e instanceof Error && 'code' in e && typeof e.code === 'string' && ['ENOENT', 'ENOTDIR'].includes(e.code)) {
|
|
147
147
|
this.aliasStore = new Map();
|
|
148
148
|
await (0, promises_1.mkdir)((0, node_path_1.dirname)(this.fileLocation), { recursive: true });
|
|
149
149
|
await this.saveAliasStoreToFile();
|