Skip to content

Commit dcc92cd

Browse files
authored
Merge pull request #10 from Kirusi/develop
Changed JSON schema validator's options to remove warning: "$ref: key…
2 parents 8dae385 + 4cde675 commit dcc92cd

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/specs/spec_0_2.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,9 @@ const reserved = {
1616

1717
const schema = require("../../ext/spec_0_2.json");
1818

19-
// Default options
20-
const ajv = new Ajv();
19+
const ajv = new Ajv({
20+
extendRefs: true // validate all keywords in the schemas with $ref (the default behaviour in versions before 5.0.0)
21+
});
2122

2223
const validate = ajv.compile(schema);
2324

0 commit comments

Comments
 (0)