Skip to content

Commit

Permalink
fix: compileAsync schema with multiple remote schemas and some recurs…
Browse files Browse the repository at this point in the history
…ive, fixes #801
  • Loading branch information
epoberezkin committed Jun 10, 2018
1 parent 15c6d07 commit 32651b5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions lib/ajv.js
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,10 @@ function _compile(schemaObj, root) {

var v;
try { v = compileSchema.call(this, schemaObj.schema, root, schemaObj.localRefs); }
catch(e) {
delete schemaObj.validate;
throw e;
}
finally {
schemaObj.compiling = false;
if (schemaObj.meta) this._opts = currentOpts;
Expand Down
2 changes: 1 addition & 1 deletion spec/async.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ describe('compileAsync method', function() {
});


describe.skip('schema with multiple remote properties, the first is recursive schema (#801)', function() {
describe('schema with multiple remote properties, the first is recursive schema (#801)', function() {
it('should validate data', function() {
var schema = {
"$id": "http://example.com/list.json",
Expand Down

0 comments on commit 32651b5

Please sign in to comment.