Skip to content

Commit

Permalink
update error message
Browse files Browse the repository at this point in the history
  • Loading branch information
ivan-tymoshenko committed Oct 21, 2023
1 parent c5bd7a4 commit 5beb72c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ class RefResolver {
const targetSchema = this.getDerefSchema(refSchemaId, refJsonPointer)
if (targetSchema === null) {
throw new Error(
`Cannot resolve ref "${ref.ref}". Ref ${refJsonPointer} is not found in schema "${refSchemaId}".`
`Cannot resolve ref "${ref.ref}". Ref "${refJsonPointer}" is not found in schema "${refSchemaId}".`
)
}

Expand Down
2 changes: 1 addition & 1 deletion test/deref-schema.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ test('should throw if target ref schema is not found', () => {
} catch (error) {
assert.strictEqual(
error.message,
'Cannot resolve ref "#foo". Ref #foo is not found in schema "relativeAddress".'
'Cannot resolve ref "#foo". Ref "#foo" is not found in schema "relativeAddress".'
)
}
})

0 comments on commit 5beb72c

Please sign in to comment.