mirror of
https://github.com/graphql-python/graphene.git
synced 2025-02-18 20:40:38 +03:00
Fixed return ConnectionType instance in ConnectionField resolver
This commit is contained in:
parent
a7cf71fdd0
commit
fe860774e8
|
@ -30,7 +30,8 @@ class ConnectionField(Field):
|
||||||
schema = info.schema.graphene_schema
|
schema = info.schema.graphene_schema
|
||||||
connection_type = self.get_type(schema)
|
connection_type = self.get_type(schema)
|
||||||
resolved = super(ConnectionField, self).resolver(instance, args, info)
|
resolved = super(ConnectionField, self).resolver(instance, args, info)
|
||||||
if not isinstance(resolved, connection_type):
|
if isinstance(resolved, connection_type):
|
||||||
|
return resolved
|
||||||
return connection_type.from_list(resolved, args, info)
|
return connection_type.from_list(resolved, args, info)
|
||||||
|
|
||||||
def get_connection_type(self, node):
|
def get_connection_type(self, node):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user