Skip to content

Commit 894feaf

Browse files
committed
fix(@angular-devkit/build-angular): compile schema in synchronously
AJV only support a single schema with the same ID, compiling schemas async can cause a race condition were multiple schemas with the same name as compiled at the same time. Closes #20847 (cherry picked from commit 43926a2)
1 parent 47283d6 commit 894feaf

File tree

1 file changed

+1
-1
lines changed
  • packages/angular_devkit/core/src/json/schema

1 file changed

+1
-1
lines changed

packages/angular_devkit/core/src/json/schema/registry.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ export class CoreSchemaRegistry implements SchemaRegistry {
296296
let validator: ValidateFunction;
297297
try {
298298
this._currentCompilationSchemaInfo = schemaInfo;
299-
validator = await this._ajv.compileAsync(schema);
299+
validator = this._ajv.compile(schema);
300300
} finally {
301301
this._currentCompilationSchemaInfo = undefined;
302302
}

0 commit comments

Comments
 (0)