Skip to content

Commit 4e0123f

Browse files
committed
fix: do not re-crawl unless necessary
1 parent e1d40c4 commit 4e0123f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/bundle.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,9 @@ function inventory$Ref ($refParent, $refKey, path, pathFromRoot, indirections, i
135135
});
136136

137137
// Recursively crawl the resolved value
138-
crawl(pointer.value, null, pointer.path, pathFromRoot, indirections + 1, inventory, $refs, options);
138+
if (!existingEntry) {
139+
crawl(pointer.value, null, pointer.path, pathFromRoot, indirections + 1, inventory, $refs, options);
140+
}
139141
}
140142

141143
/**

0 commit comments

Comments
 (0)