sf-decomposer 6.33.0 → 6.33.1
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.
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,13 @@
|
|
|
5
5
|
|
|
6
6
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
7
7
|
|
|
8
|
+
## [6.33.1](https://github.com/mcarvin8/sf-decomposer/compare/v6.33.0...v6.33.1) (2026-06-25)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* resolve child metadata types by suffix rather than xmlName ([#497](https://github.com/mcarvin8/sf-decomposer/issues/497)) ([f7f8d63](https://github.com/mcarvin8/sf-decomposer/commit/f7f8d6333a7e8e12989d40664dbc5d6e78b815fb))
|
|
14
|
+
|
|
8
15
|
## [6.33.0](https://github.com/mcarvin8/sf-decomposer/compare/v6.32.0...v6.33.0) (2026-06-25)
|
|
9
16
|
|
|
10
17
|
|
|
@@ -5,12 +5,28 @@ import { getUniqueIdElements } from './getUniqueIdElements.js';
|
|
|
5
5
|
import { getPackageDirectories } from './getPackageDirectories.js';
|
|
6
6
|
// Singleton instance for RegistryAccess to avoid repeated instantiation
|
|
7
7
|
let registryAccessInstance = null;
|
|
8
|
+
// Lazy-built reverse map: suffix → child MetadataType (for child types whose suffix differs from xmlName)
|
|
9
|
+
let childSuffixMap = null;
|
|
8
10
|
function getRegistryAccessInstance() {
|
|
9
11
|
if (!registryAccessInstance) {
|
|
10
12
|
registryAccessInstance = new RegistryAccess();
|
|
11
13
|
}
|
|
12
14
|
return registryAccessInstance;
|
|
13
15
|
}
|
|
16
|
+
function getChildSuffixMap(registryAccess) {
|
|
17
|
+
if (!childSuffixMap) {
|
|
18
|
+
childSuffixMap = new Map();
|
|
19
|
+
const reg = registryAccess.registry;
|
|
20
|
+
for (const childXmlNameLower of Object.keys(reg.childTypes)) {
|
|
21
|
+
const parentType = registryAccess.getParentType(childXmlNameLower);
|
|
22
|
+
const childEntry = parentType?.children?.types[childXmlNameLower];
|
|
23
|
+
if (childEntry?.suffix) {
|
|
24
|
+
childSuffixMap.set(childEntry.suffix, childEntry);
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
return childSuffixMap;
|
|
29
|
+
}
|
|
14
30
|
export async function getRegistryValuesBySuffix(metaSuffix, command, ignoreDirs, repoRootOverride, uniqueIdOverride) {
|
|
15
31
|
if (metaSuffix === 'object') {
|
|
16
32
|
throw Error('Custom Objects are not supported by this plugin.');
|
|
@@ -18,10 +34,10 @@ export async function getRegistryValuesBySuffix(metaSuffix, command, ignoreDirs,
|
|
|
18
34
|
const registryAccess = getRegistryAccessInstance();
|
|
19
35
|
let metadataTypeEntry = registryAccess.getTypeBySuffix(metaSuffix);
|
|
20
36
|
if (metadataTypeEntry === undefined) {
|
|
21
|
-
// Child types
|
|
22
|
-
//
|
|
23
|
-
|
|
24
|
-
metadataTypeEntry =
|
|
37
|
+
// Child types are not in the top-level suffix index. children.types is keyed by lowercased
|
|
38
|
+
// xmlName, not suffix — so 'recordType' works (suffix === xmlName lowercased) but 'field'
|
|
39
|
+
// (xmlName: CustomField) does not. Fall back to the pre-built suffix map.
|
|
40
|
+
metadataTypeEntry = getChildSuffixMap(registryAccess).get(metaSuffix);
|
|
25
41
|
}
|
|
26
42
|
if (metadataTypeEntry === undefined)
|
|
27
43
|
throw Error(`Metadata type not found for the given suffix: ${metaSuffix}.`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getRegistryValuesBySuffix.js","sourceRoot":"","sources":["../../src/metadata/getRegistryValuesBySuffix.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,cAAc,EAAgB,MAAM,oCAAoC,CAAC;AAElF,OAAO,EAAE,0BAA0B,EAAE,MAAM,yBAAyB,CAAC;AAErE,OAAO,EAAE,mBAAmB,EA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