Skip to content

Commit

Permalink
Fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
ardatan committed Dec 14, 2024
1 parent 50ac70b commit fb59ac6
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 8 deletions.
3 changes: 0 additions & 3 deletions packages/plugins/typescript/nest/src/visitor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -181,10 +181,8 @@ export class NestVisitor<

let declarationBlock: DeclarationBlock;
if (isGraphQLType) {
// @ts-expect-error - Types have separate declarations of a private property '_config'.
declarationBlock = this.typescriptVisitor.getObjectTypeDeclarationBlock(node, originalNode);
} else {
// @ts-expect-error - Types have separate declarations of a private property '_config'.
declarationBlock = this.getObjectTypeDeclarationBlock(node, originalNode);

// Add decorator
Expand Down Expand Up @@ -222,7 +220,6 @@ export class NestVisitor<
return declarationBlock.string;
}

// @ts-expect-error - Types have separate declarations of a private property '_config'.
getArgumentsObjectDeclarationBlock(
node: ObjectTypeDefinitionNode | InterfaceTypeDefinitionNode,
name: string,
Expand Down
4 changes: 2 additions & 2 deletions packages/plugins/typescript/react-apollo/src/visitor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -597,15 +597,15 @@ export class ReactApolloVisitor extends ClientSideBaseVisitor<
public get fragments(): string {
const fragments = super.fragments;

if (this._fragments.length === 0 || !this.config.withFragmentHooks) {
if (this['_fragments'].length === 0 || !this.config.withFragmentHooks) {
return fragments;
}

const operationType = 'Fragment';

const hookFns: string[] = [fragments];

for (const fragment of this._fragments.values()) {
for (const fragment of this['_fragments'].values()) {
if (fragment.isExternal) {
continue;
}
Expand Down
3 changes: 0 additions & 3 deletions packages/plugins/typescript/type-graphql/src/visitor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -228,10 +228,8 @@ export class TypeGraphQLVisitor<

let declarationBlock: DeclarationBlock;
if (isGraphQLType) {
// @ts-expect-error - Types have separate declarations of a private property '_config'.
declarationBlock = this.typescriptVisitor.getObjectTypeDeclarationBlock(node, originalNode);
} else {
// @ts-expect-error - Types have separate declarations of a private property '_config'.
declarationBlock = this.getObjectTypeDeclarationBlock(node, originalNode);

// Add type-graphql ObjectType decorator
Expand Down Expand Up @@ -270,7 +268,6 @@ export class TypeGraphQLVisitor<
return declarationBlock.string;
}

// @ts-expect-error - Types have separate declarations of a private property '_config'.
getArgumentsObjectDeclarationBlock(
node: InterfaceTypeDefinitionNode | ObjectTypeDefinitionNode,
name: string,
Expand Down

0 comments on commit fb59ac6

Please sign in to comment.