@kubb/ast 5.12.3 → 5.12.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.
package/dist/index.js CHANGED
@@ -1256,11 +1256,12 @@ function createFile(input) {
1256
1256
  const extname = path.extname(input.baseName);
1257
1257
  if (!extname) throw new Error(`No extname found for ${input.baseName}`);
1258
1258
  const resolvedExports = input.exports?.length ? combineExports(input.exports) : [];
1259
+ const resolvedSources = input.sources?.length ? combineSources(input.sources) : [];
1259
1260
  const resolvedImports = (() => {
1260
1261
  if (!input.imports?.length) return [];
1261
1262
  const sourceParts = [];
1262
1263
  const localNames = /* @__PURE__ */ new Set();
1263
- for (const item of input.sources ?? []) {
1264
+ for (const item of resolvedSources) {
1264
1265
  const extracted = item.nodes && extractStringsFromNodes(item.nodes);
1265
1266
  if (extracted) sourceParts.push(extracted);
1266
1267
  if (item.name) localNames.add(item.name);
@@ -1277,7 +1278,6 @@ function createFile(input) {
1277
1278
  }];
1278
1279
  });
1279
1280
  })();
1280
- const resolvedSources = input.sources?.length ? combineSources(input.sources) : [];
1281
1281
  return {
1282
1282
  ...input,
1283
1283
  kind: "File",