mirror of
https://github.com/graphql-python/graphene-django.git
synced 2025-07-11 08:42:32 +03:00
Use self.stdout.write instead of print when printing graphql schema
This commit is contained in:
parent
4b8db68d5a
commit
bfda8f68e6
|
@ -63,7 +63,7 @@ class Command(CommandArguments):
|
||||||
if out == "-" or out == "-.json":
|
if out == "-" or out == "-.json":
|
||||||
self.stdout.write(json.dumps(schema_dict, indent=indent, sort_keys=True))
|
self.stdout.write(json.dumps(schema_dict, indent=indent, sort_keys=True))
|
||||||
elif out == "-.graphql":
|
elif out == "-.graphql":
|
||||||
print(print_schema(schema))
|
self.stdout.write(print_schema(schema))
|
||||||
else:
|
else:
|
||||||
# Determine format
|
# Determine format
|
||||||
_, file_extension = os.path.splitext(out)
|
_, file_extension = os.path.splitext(out)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user