mirror of
https://github.com/graphql-python/graphene.git
synced 2025-07-27 08:19:45 +03:00
Allow user to specify mutation description
At the moment user is unable to specify mutation description. Mutation class documentation (`__doc__`) is assigned to mutation payload type instead of the mutation itself. We can change this behaviour so mutation class documentation will be automatically reflected in GraphQL schema (type description).
This commit is contained in:
parent
6c92e25ae8
commit
35229378ca
|
@ -77,5 +77,5 @@ class Mutation(ObjectType):
|
||||||
@classmethod
|
@classmethod
|
||||||
def Field(cls, *args, **kwargs):
|
def Field(cls, *args, **kwargs):
|
||||||
return Field(
|
return Field(
|
||||||
cls._meta.output, args=cls._meta.arguments, resolver=cls._meta.resolver
|
cls._meta.output, args=cls._meta.arguments, resolver=cls._meta.resolver, description=cls.__doc__
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user