Added context to sqlalchemy connectionfield

This commit is contained in:
Markus Padourek 2016-05-20 15:26:42 +01:00
parent 83c2cb1b27
commit 5a949ce209

View File

@ -21,11 +21,11 @@ class SQLAlchemyConnectionField(ConnectionField):
def model(self):
return self.type._meta.model
def from_list(self, connection_type, resolved, args, info):
def from_list(self, connection_type, resolved, args, context, info):
if resolved is DefaultQuery:
resolved = get_query(self.model, info)
query = maybe_query(resolved)
return super(SQLAlchemyConnectionField, self).from_list(connection_type, query, args, info)
return super(SQLAlchemyConnectionField, self).from_list(connection_type, query, args, context, info)
class ConnectionOrListField(Field):