Skip to content

Commit

Permalink
refactor: revert logic
Browse files Browse the repository at this point in the history
  • Loading branch information
darrenyong committed Oct 19, 2023
1 parent cf2a558 commit c3bbddd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/dereference.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ function crawl(obj, path, pathFromRoot, parents, processedObjects, dereferencedC
const keyPathFromRoot = Pointer.join(pathFromRoot, key);
const value = obj[key];

if (value?.$ref?.substring(0, 2) !== '#/') {
if (value?.$ref?.substring(0, 11) === '#components') {
throw new InvalidPointerError(value.$ref, keyPath);
}

Expand Down

0 comments on commit c3bbddd

Please sign in to comment.