Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug Fix: build_schema #16

Merged
merged 1 commit into from
Dec 10, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions graphene_federation/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,9 @@ def build_schema(
schema = schema or Schema(query=query, mutation=mutation, **kwargs)
schema.auto_camelcase = kwargs.get("auto_camelcase", True)
schema.federation_version = 2 if enable_federation_2 else 1
federation_query = _get_query(schema, query)
return Schema(query=federation_query, mutation=mutation, **kwargs)
federation_query = _get_query(schema, schema.query if schema else query)
return Schema(
query=federation_query,
mutation=schema.mutation if schema else mutation,
**kwargs
)
Loading