lib/graphql/relay/connection_resolve.rb in graphql-1.5.11 vs lib/graphql/relay/connection_resolve.rb in graphql-1.5.12
- old
+ new
@@ -8,10 +8,13 @@
@max_page_size = field.connection_max_page_size
end
def call(obj, args, ctx)
nodes = @underlying_resolve.call(obj, args, ctx)
- if ctx.schema.lazy?(nodes)
+
+ if nodes.nil?
+ nil
+ elsif ctx.schema.lazy?(nodes)
nodes
else
build_connection(nodes, args, obj, ctx)
end
end