Added clarifying comments related to GraphQL return types
This commit is contained in:
@@ -4,6 +4,8 @@ class GraphqlController < ApplicationController
|
||||
skip_authorization_check
|
||||
|
||||
def query
|
||||
# ConsulSchema.execute returns the query result in the shape of a Hash, which
|
||||
# is sent back to the client rendered in JSON
|
||||
render json: ConsulSchema.execute(
|
||||
params[:query],
|
||||
variables: params[:variables] || {}
|
||||
|
||||
@@ -38,8 +38,7 @@ module GraphQL
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
return new_graphql_type
|
||||
return new_graphql_type # GraphQL::ObjectType
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user