Skip to content

Commit

Permalink
Revert "Prevent subsequent build of metadata storage"
Browse files Browse the repository at this point in the history
This reverts commit cc94f97.
  • Loading branch information
MichalLytek committed Jun 7, 2024
1 parent 7d372cf commit c8a316b
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions src/metadata/metadata-storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,6 @@ export class MetadataStorage {

params: ParamMetadata[] = [];

private hasAlreadyBeenBuilt = false;

collectQueryHandlerMetadata(definition: ResolverMetadata) {
this.queries.push(definition);
}
Expand Down Expand Up @@ -176,12 +174,6 @@ export class MetadataStorage {
}

build(options: SchemaGeneratorOptions) {
if (this.hasAlreadyBeenBuilt) {
return;
}

this.hasAlreadyBeenBuilt = true;

this.classDirectives.reverse();
this.fieldDirectives.reverse();
this.argumentDirectives.reverse();
Expand Down Expand Up @@ -222,11 +214,10 @@ export class MetadataStorage {
this.argumentDirectives = [];
this.classExtensions = [];
this.fieldExtensions = [];

this.resolverClasses = [];
this.fields = [];
this.params = [];

this.hasAlreadyBeenBuilt = false;
}

private buildClassMetadata(definitions: ClassMetadata[]) {
Expand Down

0 comments on commit c8a316b

Please sign in to comment.